text:
What are your recommendations to organizing online streams of lectures?
What are the aspects you would recommend to pay attention to?
Specifically, we're organizing a seminar series, where we would also like to make the streams available online. It is not so important that the online observers are able to interact, so there could be some lag with the display online. In fact, having full chat interaction with observers like in "hangouts" could be risky, as someone from outside could interrupt the flow.
What are your recommendations on how to organize it? The aims of the stream is to allow people not attending to follow the discussions too and perhaps get more people interested through the shared link. It would be nice to know how many people are observing the link at the time. Otherwise, any ideas would be useful.
For example, we have been thinking about the balance of interaction and visibility of the online stream - it could be that if the stream is too comfortable, the participants might bother to show up, and just observe from home thus potentially unintentionally working against the seminar.
What are your recommendations in how to go about it?
Thanks!

At my previous University, the software TheRec is used. It was developed at the University of Osnabrueck (Germany). The homepage seems to be available in German only but the program is available in English language.

Hello, for those close vote voters, please see the first part of my answer and give it some time for the OP to revise the question. Online delivery is an important part of our lives but this kind of questions are nearly always approached wrong and got closed. Let's give this one a chance.

Hi, thanks for the help in writing. Indeed I hadn't read the instructions in detail and now realize it was partly a shopping question. I tried to write it for more general purpose guidelines of why and the how. On the other hand, the first "related" question to this is highly rated "What's the best way to share my presentation slides online?" and is quite similar in the question and my expected response, so I am partly confused about which questions are suitable after all. Or maybe the guidelines have developed in time? Thanks for your assistance, I will try to improve in the future!

@Penguin_Knight If I understand correctly the way SE works, ideally questions with this kind of flaws should get put on hold, edited until they are deemed appropriate, and then reopened. "Be kind and leave this opened while we change it" is not the way to go, in my view. For instance, it encourages answers to the "wrong" version of the question.

@Penguin_Knight There's no need to allow time to revise the question before closing: the question can be revised after closing and that will automatically start a reopen vote, as has now happened. Indeed, this is exactly what should happen, to prevent answers to the bad version of the question and also to deal with the possibility that the asker might not bother to revise. It's not realistic to expect that people will remember to check back in a couple of days to see if the question has been edited.

@DavidRicherby, thanks for the information. While I do not usually interfere how questions are edited (I contributed to my fair share of close votes) this particular series of questions about online teaching really speak to me and their closure and lack of follow up from the OP bug me, for at least 2 years. This one is close to what I thought can make it so I made such a plead. I apologize to all the users if my unorthodox action has caused any discord. I will see that it will not happen again.

This kind of questions are often closed due to being a "shopping question." And yet, I do feel it's important in faculty's life. Perhaps you can reword your question so that it's asking for "What to consider" rather than "Which software to use."
Now onto the question. The answer is "I don't know." It's because the choice of platform can depend on a lot of criteria and not many were presented in the question. What I'd suggest is to identify the education media person and the instruction designer in your institute and schedule a meeting with him/her.
Prior to the meeting, prepare the followings. These are the general information the specialist will need to know:

Is it synchronous (live with real time interaction) or asynchronous (not live or only partially live, with more lag time interaction.) For example, a live lecture that allows people to raise question at the same duration of time is closer to synchronous; an uploaded video of a past lecture with a discussion board for Q&A is more of an asynchronous design. The more details you can provide to the specialist, the more fitting the solution.
Is it closed or open? Do people need to RSVP and log in with user name or password? Or is it just a link that anyone can access?
How many participants are you expecting? Just a ballpark is fine.
Do you need onsite AV and technical support? This has impact on your pricing. But if none of the speakers has experience with technical troubleshooting, I'd suggest get one at least for the first couple sessions.

These are just the works you need to do with the education media person. On your side, there are a lot to think about as well:

Online course has very different design concepts. While some of us may think that it's just an extra camera in the lecture hall but it's a lot more complicated than that. You'd have to consider the pacing, consider if micro-lecture is a better alternative, figure out when to let participation or Q&A happen, and design online assessment and evaluation, etc. Resources are readily available on the Internet and in books. Consult the education media person for details.
The management of the class is also different. For synchronous, I'd suggest have one person do the teaching and one extra person (could be a TA) to manage the chat, collect and curate questions for you. It's often disastrous for the speaker to try jumping between chatting and teaching.
Test run, test run, test run, and test run more. If anything, this is the most important key to success. Find some friends and colleagues to join some test sessions. Collect information on their device and make sure there is a good diversity in operation systems, browsers used, microphone and camera models, desktops or tablets, etc. and make sure the system is as versatile and bullet proof as possible.
Develop an etiquette/technical support guide and circulate it among the participants or make it available as a download prior to the event. The guide should contain i) time and date of the event and details on how to log in. Screenshots with captions are great; ii) explain how to raise question (through chat, e-mail, or bulletin board); iii) explain common etiquette such as mute your microphone when you're not speaking to avoid audio feedback, etc.

Thanks! This is a very thorough and thoughtful answer! For our specific case, we did talk to the media person at our uni, but we did not get much help, as they seemed to be not so up to date. The points to consider are really useful! We will definately do multiple test runs, and develop some etiquette of participation. Thanks for your help in formulating the question too!


text:
My former prof switched university and now I can't ask him in person for a LOR - should I try to see him?
My former prof switched university and now I can't ask him in person for a letter of recommendation - should I try to see him in person? I've read on here that asking him via email might not be the best approach.
I could travel to that city - I have a friend living there - but it's not close and I am not sure how important it is I see him in person. I also don't want to annoy my professor with this, so I'm not sure.
The problem is only that it's been 2 years since I studied with him, and I did not do research with him, just submitted an excellent essay. So I think it would probably be good to remind him a bit of who I am. What would you advise me to do?
While "Should I ask my professor by email or in person", is related, it doesn't answer my question. I'm asking whether travelling to that professor in order to see him in person is overkill.

Basically a duplicate of this question - I thought I had read the bit about "submitted an excellent essay" ... : https://academia.stackexchange.com/questions/102562/can-i-remind-a-professor-that-i-submitted-a-good-essay-in-her-class-lor-requ

@SolarMike I think the other question is about phrasing the request, this is about visiting the prof.

@henning I did put "basically" - would have thought the OP would have sent the email by now and probably received the reference... Does this sound like an exercise in procrastination...

@SolarMike These are still separate questions though. You also don't know whether I am referring to the same professor in both questions.

So, TWO professors who won't remember you - we do... And both answers suggest sending an email...

First, it does not matter what the personal background of my questions is and there is no problem with me asking two questions about a single professor, as long as the questions are conceptually different - and they are. Second, I didn't say none of the professors will remember me, - I only said that it's been a few years since I studied, so I am naturally worried that my professors might need a little reminder. Nothing weird about that.

'And both answers suggest sending an email...' - just because the answers to the questions are pointing in the same direction, this does not make the questions identical or duplicates. This is a ridiculous argument.

Possible duplicate of Is it better to request a recommendation letter in person after class or by email?

@MadJack This is closer, but there is no "after class" in the present scenario. Meeting the prof would involve travel.

@henning Then the question should be closed as "The answer to this question strongly depends on individual factors such as a certain person’s preferences ..."

@henning it is "after class" just not in the 5 minutes after class - 2 years after...

@MadJack I think it's pretty clear that there's no need to travel, so there's an objective answer. It's not a terribly relevant question overall, but I can't see a reason to close.

@SolarMike I've read it the other way, but your interpretation makes sense as well.

@henning all this really boils down to : “send email : get reference : send application : move on “...

I don't think a visit is necessary (and I don't see where in the linked thread it says otherwise). Even if you were to visit him, you would contact him first to make an appointment, presumably by email.
Why not send a mail in which you both ask for a letter of recommendation and whether the prof would like to talk to you to refresh his memory (be it in person or on the phone)?

"be it in person or on the phone" or via Skype!

The question you link is about getting a letter of recommendation from a professor in your own university. In that situation, it makes sense to talk face-to-face. However, when the professor is in a different city, this is no longer necessary or even reasonable.
Honestly, I'd find it kinda creepy if you arranged a meeting with me and the smalltalk went
Me: So, how come you're in town? [Thinks: probably visiting friends or something and just dropped by because they were here.]
You: I spent two hours travelling here just to talk to you for fifteen minutes and, when we're done, I'm going to spend two hours travelling back.
Me: [Thinks, er, how do I say "You know about telephones, right?" without sounding like a jerk?]  Um. ... ... Ookay.

haha, i love that! yeah, true! I do have friends in that town and will be visiting this year anyways, so I would have somehow arranged it that way, but you're so right.

If he is someone who is likely to write you a good LOR then he is unlikely to be annoyed by an email asking for that. Traveling there seems like overkill to me. On the other hand, if it is really, really important to you then it is unlikely to hurt to ask him in person.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Is this violation of academic integrity if I ask a question on Github public repository and post it as an issue?
Recently, I asked a question on a public Github repository about a formula that is used in the code that is hosted on that public repository. Basically, if you are familiar with Github, you can create an issue on any public repositories to ask question, report an error, request new features, etc. I use the similar formula, that is embedded in that repository, in my research and based on my literature review that formula is implemented incorrectly in that repository and I have the reference as well. So, I opened an issue and said I think the formula implemented in this code is wrong and I think based on the literature it should be implemented differently, and asked if there is any plan to change or fix it.
Someone, that is responsible for the code to merge the pull requests or close the issues, posted a comment on the issue that I created, and said that probably nobody is aware of the problem in that formula cause there are really small community that use that code at all and that code is not used for a while, so he would be happy if I create a pull request based on correct formula and give the literature reference as well for the future people.
Long story short, I just created that pull request and I put my reference to the correct formula as well and I'm waiting for the opinion of the admin of that repository if it's possible to merge it into the original repository or not. So, nothing really strange happened here, I think.
I'm informed that my PhD adviser found that issue + pull request that I created and he thinks I'm wrong and the existing formula in the code is correct. OK, I'm fine with that. I know there is no one solution for a given problem and different people have different approaches.
But, the problem is that he is saying that: I violated the academic integrity by creating that issue and submitting that pull request, which I'm surprised and can't understand what exactly I violated here. I'm just really angry and confused and can't understand what's wrong here. I can understand he is not OK with formula and I don't care at all and I'm 100% OK to use the wrong formula, but I can't understand why I should be prosecuted with violation of academic integrity because I don't have same opinion about that formula or created that issue or pull request? Also, I read the graduate manual in our university for the 10th time and there is no such thing in it as violation of academic integrity if you don't have same opinion as your PhD adviser or if you create an issue to ask question or create pull request to fix something. Any suggestion or recommendation is appreciated.
Responses to comments: You raised some questions that I think it might help if I clarify them. One of the comments was:

Is your advisor pursuing a violation of academic integrity with your department and/or the school, or is this just a personal dispute?

My answer: No, but this personal conversation was kinda a threat and he said if he likes he would use it against me and students are always loser in front of professor, which I think is true.

Is it possible that your supervisor used the formula before and, without realising, you implicitely suggested that some of his research is wrong? I could see some people reacting badly to that, especially if they find out from a a public Github repository instead of directly from you...

My answer: No, my supervisor is new in my PhD research field and he had no experience/paper in this field before I started my PhD, and as a result of that he has a really vague and wrong idea about literature in this field and what's accepted or what's wrong in this area.

"I'm 100% OK to use the wrong formula" that sounds like poor academic integrity to me

My answer: I'm just saying that I'm OK to listen to him and use even the wrong formula and get my PhD as soon as possible and stay away from academia forever despite the fact that I always loved the academic environment and wanted to become a professor some day. But now, I have a really routine job offer in a company that has nothing to do with PhD or research and I'm aching to just get my PhD degree and start that job and maybe I could be happier in my miserable life.

Two of your statements are conflicting. First: "...based on my literature review that formula is implemented incorrectly in that repository and I have the reference as well.", but later: "I know there is no one solution for a given problem and different people have different approaches.". Could you clarify whether the original implementation is incorrect, or just different from your own? That seems to be the crux of the matter, really.

My answer: The reality is that people use the wrong formula because it's easier to understand and based on my experience wrong formula is OK within a range of 5 to 10 percent error in comparison to correct formula. It's not like nobody uses the correct formula and there are tons of literature out there that use the correct one. So, my intention was: If we have lots of other uncertainties in our model, why we induce another one when we could use the correct formula to make sure at least we are not creating another source of uncertainties when we could eliminate it without a price. Even, performance wise, correct formula is the same as wrong one.

To expand; if there are alternative methods that are also valid, and you go around flagging them as 'errors' and then promote your own method, then this would certainly be perceived as academic dishonesty.

My answer: No, the alternative method which is this wrong formula is just a really good approximation of the correct formula. Obviously, it just gives a close number to what correct formula gives you, but the wrong formula does not satisfy other properties of wrong formula, like the orthogonality of the correct formula, which is crucial in our research. So, my intention was to just use the correct thing in its mathematical sense when it is available, it doesn't have any additional cost, and it is well documented in the literature.

"I'm just really angry". Don't be. Confused is ok, but why angry?

My answer: These days I see myself as useless and miserable person that just works more than 12 hours per day and the other 12 hours that I suppose to rest or sleep still I'm thinking about my research but I'm not happy, I don't have any friends, I'm depressed, I'm nervous, I'm stressful, etc. So, yeah I'm angry that people hates me if even I tell them the truth.

at most this is ignorance. Has nothing to do with honesty. And reality is that either the adviser is an idiot (wouldn't be the first time) or OP misinterpreted the situation.
yeah, why the academic world makes people angry... that's the question. Maybe because you are punished for being proactive?

My answer: My question is ignorance of who? Me? That I want to find what's right and what's wrong? Yeah, I'm an ignorant, idiot, useless person that just devoted my whole life to something that doesn't worth.

I think you're reading that wrong. I took "I'm 100% OK to use the wrong formula" to mean that OP does not dispute the supervisor's claim that the formula is wrong; they're "100% okay" to be told that they're using the wrong formula. The question is how on earth being wrong is somehow a "violation of academic integrity".

My answer: Thank you!
Update:
Based on Wolfgang's answer, yesterday, I had a meeting with my PhD adviser and I did my best to be calm as possible and be really polite. I just asked what is wrong in his opinion about opening an issue in a public Github repository and express a valid concern based on a peer-reviewed reference (this reference is not mine nor my adviser's for those who think I shared research results without permission and this reference is more than 7 years old with so many citations) and if the owner of that Github repository is happy to accept a pull request, why it should be considered a violation of academic integrity? Also, I asked in which part of the graduate manual, this rule of approval and permission to post anything in World Wide Web is stated for my more information? Furthermore, I asked even if I'm totally misunderstood here, the repository owner could just point me to their documentation or any other reference that justifies the usage of current formula and just close the issue, and that's it.
My PhD adviser response was the pretty much the same as his initial reaction. He thinks even a single comment in World Wide Web from me should be approved by him before posting and it doesn't need to be stated explicitly in the graduate manual and graduate school gave him such an authority where he sees fit to consider this commenting as a violation of academic integrity. By the way, he thinks I'm wrong, he doesn't care about the references that I showed to him to support my idea and says he is going to send an email to the repository owner and ask him to block me cause I'm wasting the time of repository owners, despite the fact that I feel just repository owner is a welcoming person and is open to answer the questions!
I'm just shocked...!
Response to some of comments and answers:
One of the main assumptions, that I saw in the answers and comments, is that my PhD adviser is unfamiliar with Github. No, he claims that he is indeed an expert in Github, open source software, programming, etc. So, he is indeed pretty familiar with the concept of open source and Github, but his main area of expertise during his PhD and his post-docs was something else and not related to my PhD research. He just picked this topic for my PhD research, because his latest post-doc adviser developed an open source software specifically within my PhD research area many years ago and he wanted to maybe use that software and continue his collaboration with his post-doc adviser.
I can understand this behavior of my PhD adviser, when I compare his interaction with other people not just myself. Cause, logically if he is so nice and welcoming to other people, so certainly something is wrong probably with me. But, based on things that I saw, I could say: generally, my PhD adviser only respects people that are above him in hierarchical ranking or he doesn't have any authority over them. Even, with other junior professors or post-docs (my PhD adviser is also a fairly new assistant professor without tenure), he acts in a way that a few collaborators that we had during past four years just left us and some of them even doesn't reply to our emails at all now. Even, 2 or 3 years ago, I was reading his comments on Github to his colleagues for many years ago, and I was able to imagine how snarky and bad is the tone of his comments that nobody bothered to reply after 10 years or so.
Also, thank you all for your supportive comments and answers as well as your lots of useful suggestions.

Comments are not for extended discussion; this conversation has been moved to chat.

Did you check who originally submitted the code? was it per chance your adviser? does your adviser reference that wrong code in his research paper perhaps? Anyway you should be able to devise a test to show that the original code is wrong and that would make you able to show to your adviser that you are in fact correct, if he has a meltdown try to get the meltdown sent to you over an email.
I don't understand why the original repository people would care about "academic integrity" at all anyways, they would probably care more about it being correct. Your adviser is acting unprofessionally

@LassiKinnunen I know the original developer. He is a researcher that no longer works in this field. No, my adviser did not have any contribution to this repository. No, my adviser was not even aware that the wrong code exist and for the first time, a couple of month ago, I introduced it to him that this code has this functionality. I created a test case already that compare wrong and correct formulas quantitatively and shows their difference. But, he doesn't care and says even if I'm right it should not be merged because the original developers might want to use the wrong formula anyways...

That's a really strange attitude, if they don't want the patch then they wouldn't accept it. It's not like you can force patches on other peoples projects.

What a pr*ck of a supervisor.

It seems like you have to have a conversation with your adviser. There is certainly nothing wrong with your approach: You read through code on which you have knowledge and something to say; you then were proactive and wanted to fix the issue; all of these are commendable. If you happen to have been mistaken, well, that happens -- but then that's what patch review is there for.
So the stance of your adviser -- as you describe it -- doesn't make any sense to me or probably anyone here. That leaves two interpretations:

Your adviser really has awkward ideas of what is appropriate or not on GitHub.
You misunderstand what your adviser was trying to get at.

Option 1 seems unlikely, so option 2 seems like a distinct possibility to me. It's also one that can easily be addressed: Have a conversation about the issue in which you state that you are confused why the behavior was considered wrong, and ask your adviser to help you think it through.

Update: Following the addition to the original post about the conversation with the adviser, it does seem to me that option 1 above (that the adviser is a moron), however unlikely a priori, is in fact true. That's regrettable because in my fifteen years as a professor, I've never come across a situation where this kind of behavior by a professor would have been appropriate or, in fact, useful or warranted.
But, since I've been developing open-source software for more than 25 years now and have been leading open source communities for 20, I do think that it's worthwhile pointing out that the behavior of the maintainer of the GitHub repository is entirely reasonable and appropriate: We all value contributions from the general scientific community, and for all projects I know of (a substantial number), that includes cases where the person proposing a patch may in fact have been mistaken. So I continue to think that you did the right thing, and I do think that the response of the GitHub repository maintainer was reasonable and common. In other words, the behavior of the academic adviser really makes no sense to me. If I were to receive an email from someone's professor saying that their student had behaved inappropriately and suggesting that I block them from my repositories, I would certain (i) not do so, and (ii) be quite clear about the fact that I thought the student did the right thing and that the adviser is in the wrong and behaving in ways that make no sense to me. It is certainly no adviser's business to restrict what students post on the internet as long as it is in good faith and doesn't slander the adviser or university.
Given this adviser's stance, I am a bit at a loss as to what to suggest. Reasonable people are amenable to conversations, but apparently this person is not reasonable. Given that you have a job offer from elsewhere, the right choice may simply be to decide that it's not worth your mental energy to fight this fight. Or, you could talk to the department head or another trusted professor in the department -- what they will do is a separate matter, and it may not yield any outcomes that can still help you in the time before you graduate.

I support this answer - but also you may wish to have a conversation with someone who is not your adviser, but who is in a good position to discuss the situation with you. For example, another member of faculty, or a postdoc in your group. It indeed sounds like there is some sort of misunderstanding here on someone's part, and that an internet question-and-answer site like this is not going to be an easy place to discover what it is - but an active discussion with someone else who understands the context is more likely to be productive.

Well, none of it makes any sense to me

Just to make it clear, a face-to-face conversation. There's only so much you can convey via e-mail, texts, or even phone calls. Be calm and rested before that conversation. Try to understand the issue the adviser has, and explain, calmly, why you made that comment/suggestion/PR (like you have here: the original formula is an approximation, but your formula is more precise). It is quite likely there is a just a simple misunderstanding here.

Yes, face-to-face.

I support @JamesMartin's comment as well. It is too easy for people who have never had abusive advisors to say that it is likely that the advisor is misunderstood. Neither the student nor the advisor are unbiased. So you need a third-party to give you an orthogonal assessment of the situation.

The comment by @user21820 deserves more attention and is so true. It is true for many areas of life though. I have known of professors who have been completely inappropriate and have defended their actions with the response "I'm tenured so I can do whatever I want and I don't care about you." This (otherwise great) answer gives professors too much credit. They're just humans like everyone else. We're all equal.

These days I see myself as useless and miserable person that just works more than 12 hours per day and the other 12 hours that I suppose to rest or sleep still I'm thinking about my research but I'm not happy, I don't have any friends, I'm depressed, I'm nervous, I'm stressful, etc. So, yeah I'm angry that people hates me if even I tell them the truth.

It sounds like you're going through a rough time. Grad school is stressful even in the best circumstances, and yours aren't the best right now. Seek professional help from a psychologist or similar professional ASAP. Your mental health is your first priority!

As of the original issue my two cents would be to make sure they mean what you think they do, as suggested in the other answers. If this is certainly their stance you need to find a new adviser. This person could be bullying you over nonsense for whatever reason. Get out.

Would upvote more than once if I could.

Yeah I am getting strong vibes of a miscommunication between the two driven by this stress. Getting help coping with the stress and depression will help a lot as well

I think this paragraph is probably the crux of the issue. Everything you say you did technically sounds perfectly correct and professional, but your negative feelings about yourself and about your relationship with your supervisor are causing you difficulties.

I don't see any integrity issues.  Your intentions seemed to be to correct an error.  Unless your intention was to sabotage your competition, there is nothing wrong with this.
Possibily, your mentor believes you should have checked with others first, but acting rashly is not academic dishonesty.

Are you sure your adviser understood what you did? The concept of GitHub, PRs etc. may be alien to him and he could have understood that you publicly stated that his formula is incorrect, in a non-peer reviewed thing (I am making that up, just to show that interpretations can escalate quickly).
When you cool down, have a conversation with him clearly explaining the context of your update (less the "what" and more the "where" and "how")

Submitting an issue or a PR is publicly stating that his formula is incorrect in a non-peer reviewed way, in some sense.

When other people can see what you've done, and can undo it, or comment, it sort of is peer reviewed, just within the public eye.

When you say "…stated that his formula  is incorrect", who does his refer to? The PhD advisor? I'm asking because I see nothing in the OP that suggests the advisor has anything to do himself with the erroneous formula. This has been suggested in a comment, but not been confirmed by the thread opener.

@Schmuddi I think it does not really matter. What I was trying to convey is that if the advisor mis-guessed/understood what OP did and draw conclusions out of that, they may have been disastrous for OP (and it may not be easy, depending on the character, to have them change their mind)

@FedericoPoloni You're technically correct, but there are differences in how you bring such a thing. Writing an article to point how wrong someone's theory or formula is, is generally a dick move, trying to prove you're better than others. While creating a GitHub issue is, I believe, seen by most people (including the repository owner) as a helpful thing to do. Like pointing out a mistake a professor made on the blackboard,would you condemn that as well?

There are a few things to consider and clarify:

GitHub is not an authoritative academic reference. Journal papers are expected to be thoroughly reviewed and free from most usual mistakes. They have their process for correcting mistakes, which is different from GitHub, where a single person and not necessarily a committee decides what is best for the code. Maybe your advisor does not understand this. In fact, you might quote publications that describe GitHub code, but citing GitHub is pretty much like citing Wikipedia.
"Wrong" equations in code might still yield correct results. So it is important to clarify what exactly is the suggested change and impact of the concerned equation and its two versions. EDIT: From OP's clarification, it sounds like the "wrong" formula was actually an "approximate" expression. Never say an "approximate" equation is wrong, in many fields, accurate formulas and models are either unavailable or really hard to handle, people might discuss a lot on whether a given approximation is reasonable or not, but simply claiming it to be wrong is lacking maturity.
Science is not about discussing who is right or wrong on the basis of opinions, is about proving what's wrong and what resists (Popper's) falsification. Try to design tests or experiment which may assert what is right or wrong.
Not a breach of academic ethics to participate on GitHub, unless your pull request entailed some intelectual property issue. In some research environments, you are required to waive all the products of your work to whoever is paying you (and that makes perfect sense). So a code fix might be understood to be "intelectual property" which you might not be allowed to waive to the public without someone's authorization.
Also, it is not a breach of academic ethics to point out when things are wrong, I'd even say it's an academic obligation. However, how you do this might be a breach of social norms. I'd be very pissed at you if you publicly claimed my research to be wrong without even talking to me first, as doing so is common courtesy. It would be much worse if you were actually wrong, as people who are eager to point other's mistakes often dislike admitting mistakes of their own, let alone making reparations. Of course, if I post a repo on GitHub, I'm expecting people to raise issues on it, and do so publicly. But normally, you talk in private first if you think someone has made a mistake. I think that is how your advisor is framing these events. You might go to him and say "I maybe should have talked with you first". But prefer to do so after completing item 3.

Side note on #3: In cases where you have subject-area knowledge that the software developers don't, designing meaningful, accurate tests is one of the best contributions you can make.  It creates a nice, evidence-based way to judge whether an implementation or proposed change is correct, even if the developer doesn't completely understand the subject at hand.

Never say an "approximate" equation is wrong Yes! Approximations are used in many fields. Use PI as 3.14 is not "wrong" is a good enought approximation for most pratical problems. What you should concern is if the approximation is good enought for the problem it's trying to solve and if the error is acceptable.

Approximations are scientifically/mathematically wrong if not clearly indicated.  But they can potentially be wrong in a helpful way.  Being right and being helpful are not the same.

The results of teamwork are not solely yours, and you have to be mindful how you share them.
As Mefitico mentioned in their answer, you may not have the rights to use the code you offered to that project. It's important to note that "open source" or "on GitHub" doesn't mean "do whatever" (though there is a license for that too). For example, the popular MIT license includes the provision:

Permission is hereby granted, free of charge, to any person obtaining a copy of this software … to deal in the Software without restriction, including without limitation to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software …

— The MIT License (via Open Source Initiative)
If you were the sole copyright holder, that would be fine — you could offer such a license to your code, and the project could include your code in their code. But it's very likely you're not the only copyright holder:

If this is group research, you may share copyright with your advisor.
If you are a paid researcher (e.g., supported by a grant or research assistantship), there is probably a clause in your contract that grants a license to the university or institution, which may be in conflict with the license you would grant to this project.
Your contract may even grant sole copyright of any results of your research to your university or the institution that funds your grant.
If you want to publish your results, you may have to transfer copyright of your published material to the journal.

So as you can see, the results of your research really aren't yours to share freely (even if that feels like the goal of research). This is a very common issue for people who write software professionally. It's important to talk with your advisor about what you can and can't do with the results.

All that said, it's probably not going to be a big deal. Likely no one will care that some niche open source project has a few lines of code based on this research. But the road to hell is paved with good intentions, and it's easy to get into trouble if you don't pay attention to your licenses.

No. There is no research result here. It's like you are claiming nobody is able to use Navier-Stokes equation cause Navier and Stokes are copyright holders. This equation is well documented in books for decades and it's not something that I discovered or my adviser discovered or it's a research result at all.

@AloneProgrammer I can't agree or disagree because I don't know your full situation, but I'd push back based on this sentence in the question: "I use the similar formula, that is embedded in that repository, in my research and based on my literature review that formula is implemented incorrectly in that repository and I have the reference as well." It sounds like you shared a implementation informed by research, which could be a result. An implementation is very different from an abstract theorem.

@AloneProgrammer To expand, Navier-Stokes is a theorem/formula, but particular Java code to calculate values based on Navier-Stokes is different is protected by copyright. Also, remember that academic integrity is different from pure copyright (which my answer focused on). It may be legal to share something but still violate your agreements with the university, e.g., self-plagiarization (not the issue here, just an example).

The employer may have and excercise the right to see & decide what leaves the institute. Copyright also isn't the only right to consider here: I've been at an institute that did technological development regularly leading to patents. The policy there was pretty much that nothing should be made public unless specifically allowed (however unpatentable). And copyright does not only cover code, but also written texts of any sort, and novelty of the idea behind is not required (though there needs to be a certain amount of intellectual effort, it must be nontrivial).

No, posting an issue on GitHub is not an academic integrity violation
Based on the facts that you have laid out, there is nothing that remotely resembles an academic integrity violation. You say you have provided a reference to the "correct" formula. I understand you to mean that both the approximation and the exact methods are published and widely known. Providing a reference to published work is never unethical. (Willfully misrepresenting it is, but there is no indication that you are doing so, and that does not seem to be what is motivating your PhD advisor's accusation.)
As a suggestion, you should ease up on calling the old implementation the "wrong" formula, since you later clarify that it is a commonly used approximation that gives answers within 5-10% of the exact formula. (From your additional detail, there is no indication that this is what is motivating your PhD advisor's accusation either.)
Other Considerations
About GitHub and Academia
Many academics contribute to projects on GitHub. If you are working in a STEM field, it is almost beyond belief that your advisor would not be familiar with GitHub (at least know that it exists, how it works, and that colleagues are using it), or would not understand that posting code improvements, created by you, and based on properly on cited sources, is not an academic integrity violation. This accusation is completely unhinged. If your advisor is not familiar with GitHub, he has a moral obligation to educate himself before raising the very serious charge of an academic integrity violation.
An important project in my field (I am not a contributor) is PySAL. If someone were to find that a particular formula or algorithm in that library were generating a result that was incorrect, approximate (where an exact solution was available), or just slow and could be improved, that contribution would be welcomed by the maintainers (as it was by the maintainer of the repo that you contributed to). An example that might parallel yours is Improvements to distance functions?, which discusses different methods for measuring Earth distance. Whether that person's PhD advisor valued this contribution--many would, some would not, particularly if it was outside of their field and/or they thought it was interfering with RA responsibilities or your own progress to completion--there is no world in which they would consider a GitHub PR with a properly cited source to be an academic integrity violation.
My own experience: I have been doing redistricting research for a couple of years, and have created or contribute to a number of repos in this field. I often post code related to other topics of interest as well, and post and make use of educational material posted by others in my area of teaching, Geographic Information Systems.
About Protecting Yourself
A number of the responses seem to be trying to consider ways in which your advisor could have misunderstood, or ways in which you might have stepped over a line. You have provided a number of clarifications. However, the facts as you have presented them seem so clear cut, and his accusation so unfounded, that you need to consider how to protect yourself, and how (or whether) to complete your PhD with your current advisor.
Unfortunately, many academics behave in very shitty ways. I'm not certain that we are worse than other industries--finance, law, Hollywood, and many others have a lot to answer for--but it is far too common for graduate students to have to put up with abusive PhD advisors, who often are also work supervisors (if you are a Research Assistant), and who can utterly sabotage your PhD if they choose to. Furthermore, since the emphasis is often on education rather than employment, grad students do not typically get training on workplace harassment and how to report it.
You say that you are depressed, overworked, have no friends, and want to leave academia after completing your PhD. You need to consider your options and make use of available resources.
Things to do immediately

Seek help from counseling services on campus.
If you are a member of a union, e.g. graduate students union, or if you are an RA or TA and are a member of a bargaining unit, report your interaction now, and ask them if you should be concerned and what your options are.
If you are an RA or TA you should report your interaction to HR, perhaps to an office that deals with workplace harassment. If you are not part of a union, reporting to HR will be a first step. If you are part of a union, I would talk to the union first and see how they recommend proceeding.
Talk to your department chair. You may not be able to get them to do anything, but it should at least give you an idea of what you're up against. Present the facts as neutrally as possible, and ask if there is anything you should do. If the chair does not know what GitHub is and/or seems uninterested in your concern, and closes with "You should talk to your advisor about it," there probably isn't much more to accomplish with them. If the chair seems concerned (and knows what GitHub is), they might offer to talk directly to the advisor, or seek to facilitate a discussion.
Do not tell your advisor about any outside projects, going to the gym, going on a date, seeing a counselor, or anything related to anything outside your thesis research and job responsibilities (if any).

Things to consider working toward

Can you switch advisors? This is often difficult, but plenty of graduate students do it. Sometimes grad students put up with awful advisors because of their reputation in the field, but you say that your field was new to your advisor when you started your PhD. Is there anyone else in your department who is working in this field, or a related field, who would be willing to step up? Is there someone else on your committee who could take over as advisor? It may even be possible to change programs, as disciplines are often represented in multiple departments.
Can you apply to a new PhD program? This sucks, but if there is really no one else at your university that would be a suitable advisor, it is worth exploring. Do you know faculty at other institutions from conferences? It might be worth reaching out to one or two that you have met to discuss options. You do not have to say why you are looking to leave your university at first, though if you decide to pursue this option, it will doubtless come up later.

In the end, you may have no choice but to try to see it through with this advisor. In which case minimize your interactions with him, make use of mental health resources, and start reviewing Academia.SE questions related to bad advisors:

Advisor's Negativity
What to do when phd advisor wants me to work on side projects but i'm starting a post-doc?
Help! Professor/Advisor Refuses to Publish Any of His Students' Research

There may be a few situations in which, from what you describe, your advisor considers an issue of academic integrity. It is not clear what the exact situation of 'your reference' is referring to though. These are pretty speculative until your question is more refined.
1) You are referring to work that is yet to be published or reviewed by your advisor and are publicly releasing it.
2) Your advisor does not think you are clear on the github issue that the reference is to your own work and not the original literature, and it seems unethical to them that you are claiming it is your algorithm when it originally came from your literature review
3) After reading and finding the issue, your advisor noticed that the original code is correct, and that your implementation is incorrect. If you had published this before, your advisor may be making a jump to a conclusion that you were unethical in how you explained your results or your paper to them, which they did not realize until seeing a correct implementation.

I am sorry for what happened to you, even if I don't know wether wrong formula is actually wrong or not.
A country/cultural tag could be interested there, since I think your last edit presents a very rude reaction from you supervisor.
I would recommend something that is often said in company world, but is actually a matter of fact and should be thought about everywhere: Write a mail with feedback of your meeting.
You could do it right now with what you described in your edit during second meeting:

First, explain the facts. Don't use what you said in this post, because it could be misintepretated. Give link rather than explanation. And be overpolite: for example: "I had a comment [link to the comment] on the GitHub [GitHub]. Thank you for the meeting today about this issue".
Second, state your case: You want to improve the GitHub repository. You want to use a good formula (not correct or wrong, but the best fit) for your PHD
Third, ask questions: You need to force your Administrator to explain himself in the mail: "Do I need to delete my comment?" "Do I need to ask you before posting in the future?"
Fourth, trace back what he said: Your supervisor is going to burn you in front of the GitHub Administrator: Trace it by giving the contact (pseudo, mail) of the Administrator in the mail with something along the lines: "You said during the meeting you want to speak with the Administrator: here is the contact"

Besides this advice, I have another subject to raise. I am not familiar with GitHub, but I feel from your text that your supervisor is not familiar with Web and GitHub? Maybe he thinks GitHub is something like a research paper? Then it would explain his behaviour.
But if you think your had passed this step with your supervisor, and that he is of bad faith, you could find a pretext to put in copy another one of the Academia, maybe a superior to both of you.
Anyway don't be too offensive for now. Keep your calm, stay polite, ask question, write done as much as possible.

The advisor is silly but you shouldn’t have contacted them about it in the first place. There was no point, they aren’t your personal censor. I think you could have confused your advisor by contacting them in the first place, and they misunderstood what’s going on or simply had a bad day and decided to be nasty to you.
In other words: there’s nothing to it. Remember it, keep the emails, print them to a PDF and add the PDF “prinout” of the GitHub issue you submitted as well. In case the project were to somehow vanish, your advisor won’t be able to get silly ideas and blackmail you just because they get another case of a bad day or a bad week.
Otherwise treat it as if your advisor had a brain fart. And don’t tell your advisor anymore every time you go to the restroom, or next they’ll accuse you of wasting University water on purpose :/ Sadly, such people exist: they have a tendency to be unpredictable and you reach out to them with the best of intentions and they just turn it into a nightmare. I’m really sorry you got such an unreasonable experience. It was through no fault of your own.
A reasonable response from your advisor would have been to inform you that it’s fine and that there’s no reason to ask for such things.

Let put it this way. You are a very good, devoted employee, and your adviser is a Project Manager. Due to the lack of communication in the beginning that your PM didn't explain the Contract for you or make sure you understand it fully. Any on-progress work you have been working on is subject to your institution under the management of your Manager. He was angry which was not very professional, you accidentally shared your idea stemming from your research to an opensource project was wrong too. So no one is right here. Your PM couldn't use your correct formula anymore since it was merged to that open source so he decided to use another formula. Dont be angry with how complicated in terms the academia created. You can choose to finish your project in your current institution under the management of other PM/advisor or still the same advisor, which depends on you if the PhD is important in your career plan. Otherwise, you can switch to the industrial field and find a suitable position to pursue what you like/love to do. Dont think too much since I have been there. Best of luck to you!!!

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
I got accepted into a math PhD program but I don't feel adequate enough to attend
I got accepted into a school that I really wanted to go to for a math PhD. I finished my masters and I love math very much. It's something that I've always been extremely passionate about. I used to always go for representation theory seminars with an old professor that I did research with (we mainly did work in certain parts of representation theory) and I thoroughly enjoyed them even if I couldn't fully understand.
But I suck at math. I think I only was accepted because I'm a woman and Indian. Everyone is so smart in all my classes. During my undergraduate degree I was amongst the top of the class but once I got to a master's, I was at the bottom of the barrel. I can't understand things the way everyone else does. Everyone is always able to engage in the lesson and it takes me 4 hours just to understand the smallest thing, it's depressing.
I still got A's in almost all my classes but it wasn't hard to get an A in the classes. It's not like I deserved it and it probably deceived admissions officers.
What makes me even more depressed is that on standardized tests, I can score in the 95th percentile in english/verbal without ever cracking open a book. But it's just not the same in math, I have to try so hard and even still I don't do nearly as well as I would like.
My strengths aren't in math, I am very good with english, history and philosophy. My professors from my undergraduate degree would always encourage me to pursue these fields but I love math so much more even though I'm not good at it. I just don't know what to do, I enjoy those subjects recreationally but not something I want to pursue full-time right now. I would love to get a second master's in philosophy but it's not my priority and if I never got it, I think I'd be fine just reading the literature on my own.
Anyways, even the most basic math facts I will forget. It's embarrassing to be a PhD student and forget things so easily. I don't even want to make friends because I'm scared they will start talking about math and I won't know what they're saying
Should I just quit?

Perhaps you may also benefit from talking to your (future) advisor about these thoughts. You may be surprised at how many of your professors went through very similar episodes of imposter syndrome when they were grad students. From my personal experience, I've never seen anyone successful in their graduate career say that they, without a doubt, felt that they deserved to be in their program.

Have a look at the Q&As under this tag: https://academia.stackexchange.com/questions/tagged/emotional-responses

"I think I only was accepted because I'm a woman and Indian" that might have caused bonus points, but I doubt that is the reason you were admitted. Be more honest with yourself about this :–)

The standard advice I have heard is that PhDs are a marathon, not a sprint. If you're worried about doing well relative to your PhD students, then you might be  worried about the wrong thing :) (That being said, there is a life after the PhD too, and you should use the expectations for that to calibrate your expectations from yourself during the doctoral program instead of at this stage).

Are you familiar with https://en.wikipedia.org/wiki/Impostor_syndrome ? It might be worth considering whether your problem is your ability or your confidence in that ability. You got an A in almost all your classes, you say that wasn't hard but how many of your classmates also got As ?

Why did you apply if you do not feel you have the adequate skills?

Just a quick note, if you are interested in mathematics and philosophy, data ethics and AI ethics is starting to get real traction in universities. I saw a few positions posted for faculty members specializing in those areas this past fall. It seems like a strong fit for someone with a math and philosophy background.

Don't worry, you'll continue feeling inadequate long after you've been awarded your Ph.D. ... ha-ha, just not kidding: It's called Impostor Syndrome, like @TimB notes.

I went to school with people like you: young Indian women who felt like they were there to fill a quota, not confident in their abilities, and who would look to me and some of my peers and see people who just "get it" while they struggle for hours to barely succeed. In the end, most of us left the program, and they kept going, many of them finishing their PhD and others still working on it but on track to finish soon. I know it's just a few data points, but in my experience, persistence and dedication will take you further than raw talent ever could.

I advise reading "Surely You're Joking, Mr Feynmann!".  Even Richard Feynmann felt the same way at one point.  His answer “You have no responsibility to live up to what other people think you ought to accomplish. I have no responsibility to be like they expect me to be. It's their mistake, not my failing.” At that point, as I recall, he took a day off, went to a restaurant, watched a plate spinning ... and solved the nuclear physics problem he was stumped on.

Please please please also read the very highly voted Q: https://academia.stackexchange.com/q/2219 (about "How should I deal with discouragement as a graduate student?") and some highly voted answers to that question!!

First off, congratulations on being accepted to the PhD. That means the faculty have carefully evaluated your application materials and decided that you are a promising young mathematician. They are experts and they think you have what it takes to finish a PhD.
No one gets admitted just because of their gender and/or race. It would be a waste of the department's resources to admit unqualified students and it would be a disservice to those students -- setting them up to fail.
It sounds like you have Impostor Syndrome. The truth is that almost everyone, from time to time, feels like they don't belong. I have felt that way at many points.
No, you should not "just quit". You have a great opportunity in front of you. It sounds like you have other things that you want to consider doing. Perhaps you will decide that those other opportunities are better for you. But, if you do turn down the PhD, you should not think of it as quitting. You should think of it as taking a positive step in another direction.
That said, academia is hard. And I would not advise anyone to do a PhD unless they really enjoy research.
You should think seriously about what you want to do, as it sounds like you are uncertain about where your best option lies. Talk to people you know personally, as they can best advise you.
One thing to note is that a PhD should give you some flexibility to study other things or, better yet, to combine different research topics. My PhD program allowed — required, in fact — me to take graduate courses in totally different fields.

thank you, I know PhDs take serious ambition and dedication. I think I have that but I'm not sure about my actual ability in the field, which is what confuses me. I think I have a better ability to perform in other subjects: specifically philosophy. But I also have the ability to take courses in this field at a graduate level not for credit i.e. just sitting in on the courses. granted, I have the same opportunity for classes in mathematics however I do want to get a PhD in the field. I'm just not sure if I can do it and if it would be a waste of time where I'd ultimately drop out

Agree with this answer. Sounds like you do have the capability. You have just found a level that requires more work. As long as you are motivated, no reason to believe you should not see it through.

I'm a graduate student and 100% of the other graduate students I have interacted with at my university have expressed feeling impostor syndrome at one point or another (or are feeling it now).

In addition to "enjoy research" I'd say "or need to get some specific research done".

"No one gets admitted just because of their gender and/or race. It would be a waste of the department's resources to admit unqualified students and it would be a disservice to those students -- setting them up to fail." Unfortunately, I would not make that statement too readily. It's certainly a matter of debate, at least.

@jpmc26 for regular university admissions, perhaps... but for PhD level? I suspect that's not so much a thing.

@DoktorJ I hope not, but some disagree. I wouldn't dismiss the possibility out of hand. I am not suggesting that the OP should refuse the offer or anything, of course, but knowing the truth will always inform our actions. thinks Although, that book's thesis is not that the students in question are totally unqualified, but that they are being admitted to programs that beyond their current ability. That may be an important distinction to make.

I think you should give the math PhD a try. I am almost exactly like you in terms of strengths and weaknesses, yet doing a stats PhD was the best few years of my life, and now I am smarter and better-rounded than if I'd done a PhD in a personally "easier" subject.
Math has always been my hardest subject in school; all the way through elementary school, high school, and college, I disliked math classes and excelled at the other subjects. I'm quite error-prone when handling messy formulas, and I have a hard time manipulating abstract mathematical objects in working memory. But, like you, I was a good student and managed good grades in math, even though it was definitely my weakest subject.
Then somehow I fell in love with statistics and, rather to my surprise, found myself at a very selective statistics PhD program. I had the time of my life and graduated early. Here is what I'd recommend:

Know your own intellectual strengths and weaknesses. Imposter syndrome is a real thing, but don't let others tell you to automatically attribute your perceived weaknesses to imposter syndrome. Rather, calibrate your strategies and expectations to your own strengths and weaknesses. For example, like you, I easily forget useful math facts, which is a real pain on timed, closed-notes exams. As mentioned above, I'm also pretty slow at actually doing math accurately. Therefore, for high-stakes exams like the quals, my study strategy focused on training my weaknesses aggressively through assiduously memorizing math facts. During the exams themselves, as you'd do at, for example, an athletic event, my strategy switched to playing to my strengths in order to earn as many points per unit time as possible. For me, that meant using my strong understanding of the concepts to earn lots of points on that front, and quickly bailing on any integral that seemed like a pain to simplify (because the probability that I'd mess it up is pretty high, and it's just not a good points:time ratio). Again, this kind of attitude is not imposter syndrome: you are actively working to improve your weaknesses, while finding ways around them on tests.
Math research is tremendously different from "school math". With no false modesty, I have many classmates who are much better than me at math. However, many students who love and excel at school math neither love nor excel at research math. Among the key differences are:

The role of high-level creativity and conceptual understanding is much higher in research math than school math. Major research advances don't always come from breathtaking mathematical shrewdness. Sometimes they arise from out-of-the-box thinking or the creativity to recognize and repurpose a useful analog in a disparate subdiscipline. Like me, you may find yourself quite adept at the latter.
Research math requires many other skills besides muscling through integrals. Given that you excel at humanities classes, I suspect that, like me, you're an excellent writer. You will spend a lot of time writing when doing a PhD and subsequently as a researcher. If you write, say, 30% better and faster than the average math PhD student, you will find yourself flying through your dissertation and paper submissions. I wrote each of my 3 dissertation papers in 1 week. This more than made up for the time lost along the way to asking Wikipedia for the 844th time how to do a Taylor series expansion.
Research math is also the ultimate "open-book exam". There are no time limits, and you can Google Scholar to your heart's content. This also means that, as discussed above, you can play to your strengths. For example, whereas others with perhaps more mathematical agility develop new research directions from the bottom up by playing with formulas and combining things in clever ways to see what happens, this does not work for me: I simply get stuck in an algebraic morass. Instead, I work from intuition and conceptual understanding first, then reach for simulation tools, and only then put pencil to paper.

Good luck with your decision.

"Many students who love and excel at school math neither love nor excel at research math." This is so very true. In research, persistence is often means more than brilliance. Also, I agree with your comment about the importance of writing. Not only is writing critical for papers and grants, but writing well is usually linked with being good at organizing your ideas and research plans.

Ah, yes, another very important point.

Whether this is "impostor syndrome" or not, you should realize that you can always quit later.  Just because you start a Ph.D. program, doesn't mean you have to labor away for 5 or 7 years at something you suck at.  Try it for a year and see how things go.  If you still love math and still get A's, carry on.  If you can't stand it, then drop out.  At least then you'll know for sure.  You won't spend the rest of your life wondering if you should have given the Ph.D. a shot.
If you don't drop out.  Swell.  If you do, the year is not wasted.  You still learn some valuable math that you can put to some use somewhere.  Some graduate credit might transfer to the philosophy department.  If you like teaching, then you will have taken a few more courses which will enhance that skill.
Win-win.

If you [...] still get A's, carry on. Perhaps I misunderstand the nature of Ph.D. programs, having personal experience only with undergraduate studies, but I would phrase this a bit more softly. While 'A's are an excellent sign you should continue, so are 'C's. For someone who has already passed the myriad gauntlets of academic excellence required for acceptance into a Ph.D. program, finding your skills to be "average" amongst a group of exceptional peers seems ample reason to continue a program you enjoy.

@jmbpiano It depends on your institution and program, but when I attended graduate school in mathematics (I left it to pursue other opportunities and didn't finish) the grade scale was different from undergraduate programs. A class you "passed" with a "C" did not count towards your requirements to graduate. "B" was the lowest "acceptable" grade and better reflected "average" achievement in the course. "F"s reflected someone who neither requested an incomplete nor completed the work and "D"s were virtually unheard of.

@jmbpiano My experience also backs up what TimothyAWiseman said. Whereas a 'C' grade in an undergraduate class often means "average", in grad school (again, in my experience) the standards were different such that 'A' meant "good", 'B' meant "marginally acceptable", and 'C' meant "inadequate". 'B' was considered the lowest passing grade, and 'B-' or lower counted as a failing grade. (Why it was done this way, I have no idea, but that was the system at my program and my understanding is that it's a fairly common one.)

@TimothyAWiseman; David Z- Fair enough. I suspected there might be some differences in the way grades are handled at the doctorate level, but did not know for certain. I think the core idea still stands, so rather than retract my comment entirely, I shall simply amend my statement to "so are 'B's", in that case. ;)

Investing a year is not nothing—after all, that’s a year of your life, and we get a distinctly finite number of those. They’re really valuable. So I would recommend spending a bit more words in this answer on the examples of side-benefits to pursuing a PhD, even if you don’t wind up getting one (new learning, research opportunities and experience, networking and relationships, the Master’s degree most PhD programs offer when you finish classes, etc.)

@KRyan No one said it was "nothing."  I said "not wasted", which, just the opposite, implies that I think it's valuable.  The OP is intelligent enough to connect the dots.

This is misleading advice.  The first couple years of math grad school are unlikely to be the same as the last three or four.  It's quite a different experience to take classes and qualifying exams from doing research.  I found a significant number of people great at doing the latter didn't necessarily excel at the former.  So how do you know if you're going to be good at research?  Unfortunately, there is no easy answer.

@Chan-HoSuh  Sort of a bizarre comment.  Your questin is "How do you know?" My answer is "You have to try and see."  And you find this misleading?

You should first think about what you plan to do with your math PhD, should you stay the course and complete it. It's surprisingly common for people to not consider this.
There are two common reasons for doing a math PhD. One is to do research. A PhD is required to do research, and a math PhD is required to do math research.
A math PhD would also help you get a good teaching job, possibly in a math related field.
There are other jobs for which a math PhD isn't required, but is helpful. E.g. finance. But you don't need a math PhD to go into finance.
However, you should be aware, if you are not already, that doing a math PhD is hard, and math research is harder, and commonly only done by people who are really, really into math, consider math among their primary interests in life, and possibly the main professional one. Also, these days math research is extremely competitive, and it's hard to get a decent math research job.
The bottom line is, try to be aware of where you are going, and whether it is somewhere you want to go.
I only mention these obvious facts, because it is my experience that graduate schools and math departments do a very poor job of educating graduate students about these issues. Unfortunately in some cases there is also a conflict of interest. The department needs cheap labor to teach their classes. Often this cheap labor is obtained from graduate students. This is true in the United States, at least. You don't say where your location is.
I also happen to be Indian, and was in math departments for a while. I was better than most people I knew at math, usually by a long way, but it was difficult for me to perform at the level that would have been required for a successful research career. Also, I don't know if, at the end of the day, whether I was interested enough.
I don't think anyone here can advise you whether you should be doing a math PhD or not, but again, consider carefully whether what you are doing is something that you really want to do, and whether the direction it is taking you in is a direction in which you want to be going.

This is the most realistic answer.

Don't quit.
When I began my Ph.D studies (in computer science, not mathematics) I'd been out of undergrad for five years.  I was certain I'd forgotten everything I once knew and I was terrified I'd be sharing a classroom with people who had just finished undergrad and had all their learning fresh in their minds.
On the very first day of class, in my very first class — Advanced Algorithmic Analysis — the prof stood at the whiteboard.  "We're going to start right where we left off in undergrad," he said, and began littering the whiteboard in really dense math that I didn't understand at all.  I looked around the room and everyone was just nodding: they clearly understood it perfectly.
After ten minutes the professor concluded his derivation.  "Is that all clear?" he asked us.  "Does anyone have any questions?"
I was too scared to put my hand up.  I had decided I was going to drop out that very day.  I could not compete with my classmates; they all understood this, and I had no idea what was going on.
"In that case, could one of you explain to me what I just did?  Because I made all that up.  It's nonsense."
For the next ten minutes we received a kind lecture about how all of us were in the program because we were smart people with a demonstrated track record of understanding things.  If we did not understand what was going on in a class presentation, that was a sign something was wrong with the class, not that something was wrong with us.
I stayed in the program.  I'm glad I did.

You are absolutely not alone.  Other people have already mentioned Impostor Syndrome.  It's real and a lot of people suffer from it.  The best advice I can give you is to be open with people that you have it, and — this part is very important — ask questions, even the 'dumb' ones.
Graduate school success belongs to the people who are willing to ask the 'dumb' questions.  And very often there's nothing dumb at all about the questions!

What a great story!

First of all, math classes are hard. I struggled in them, my peers struggled in them, everyone struggles in them. Its new material and not entirely intuitive (e.g. Ito Calculus). As for not remembering everything, that is pretty normal as well. This seems to be more common as you further and further specialize. Within my area of expertise, I could have a good grasp of knowledge, outside of that bubble, its a little vague.
You might be interested in a more applied field that can take advantage of your linguistic abilities. Applied statistics is a massive field with lots of low hanging fruit. This can range from anything to health outcomes based on social media posts to how well students perform after a policy change. You take the best parts of math and then you apply it to real world problems. That said, this does likely mean more probability and linear algebra, though you can have a surface level understanding of both those areas (like myself) and do good work in statistics.

Remember, the admissions committee aren't a charity organization. They'll only accept you if they think you're adequate enough to attend the program. And if they think you're adequate enough, you should certainly not think you "suck at math".
Have some confidence, and think positive! You've been accepted at a school when many others who want to attend were rejected. You're a success story! Relax, work hard, and enjoy the program.

I think you should follow your instincts on this one.  Some people may give you the "don't worry" message because it makes you feel better.  But I get the impression that you are putting down rational inferences, not just irrational self doubts.
Admissions committees have to fill slots and bring people in all the time who don't make it through.  Of course they prefer not to get weaker candidates or those who won't make it through from persistence/desire/love (and the two are correlated).  But it doesn't really hurt them that much and they have statistics in mind that some percent of students won't fit.  The real tragedy is to the STUDENT who wastes productive years and is miserable.
So follow your gut on this one.  Look for something that uses some of your verbal skills and is not so, so, soooo hard core math as a Ph.D. in math.  Go work for McKinsey or Microsoft or the like.

You can absolutely decide that you're not suited to the math PhD program. However, before beginning the program is not the time to make this decision.

But I suck at math. I think I only was accepted because I'm a woman and Indian.  Everyone is so smart in all my classes. During my undergraduate degree I was amongst the top of the class but once I got to a master's, I was at the bottom of the barrel. I can't understand things the way everyone else does. Everyone is always able to engage in the lesson and it takes me 4 hours just to understand the smallest thing, it's depressing.

This isn't necessarily a problem. Different people have different ways of learning. Me, as soon as somebody starts presenting equations on a slide, my brain switches off and I don't get much out of the lecture - I need to read through that kind of material by myself, in my own time. Sometimes it takes me several readings to get through it, or I have to try out an example before the abstractions click for me.
It might be worth your while to read about different learning styles and see if you can identify what strategies work best for you. I would also strongly suggest talking to somebody at your university about your situation (adviser, support staff, whoever you're most comfortable talking to).

Anyways, even the most basic math facts I will forget. It's embarrassing to be a PhD student and forget things so easily. I don't even want to make friends because I'm scared they will start talking about math and I won't know what they're saying

You might be surprised at how many of your fellow students are concealing the same worries. I still have to look up "basic" facts quite often, but that's okay; real life isn't a closed-book exam.
Nobody here can say for sure whether you should persevere with the PhD. That depends on too many factors - some people manage to complete doctorates but at too much personal cost, or they find that the doctorate doesn't position them for a satisfying career. But I wouldn't quit at this point just on the basis of "not being smart enough".
IMHO, the link between "PhD" and "clever" is often overemphasised. Yes, you need some degree of intelligence to do a PhD, but other factors are also important - material support, self-discipline, resilience, enthusiasm, etc. etc. I can pretty much guarantee that some of the smart students you're envying right now will drop out of their PhD programs because they can't handle those other challenges.

Often the people who excel are not just those who have played to their strengths, but also those who have overcome their weaknesses.  The skills and talents you have in other realms may well help you outdo your peers if you can only make it past the obstacles that are stopping you now.
With all that said, there's real evidence that being a negatively stereotyped minority in a given field can significantly lower your performance below your natural abilities, especially if you dwell on the stereotypes.  Claude Steele (provost at Columbia University) has extensively studied this topic --you may find his book, Whistling Vivaldi valuable, it includes some practical strategies to combat the stereotypes.
You should also not be afraid to ask for extra help.  One of Steele's findings is that low performing students and negatively stereotyped minorities are much less likely to seek out help because of embarrassment.  They are unaware their high-performing classmates are often quietly taking advantage of a wide range of extra help, including peer study groups and one-on-one sessions with their professors.

I finished a Physics PhD and I felt the way you're describing for most of the time.  My adviser complemented me about 3 times if I remember correctly.
For me, teaching (as a lab TA) was real boost to my confidence and understanding of Physics (which is pretty close to math).  Teaching was also where I started to see interconnections between subfields that I didn't grasp as an undergrad.

I want to posit a few things that you indicated:

You are very good at mathematics, but you need to work hard at it.
You are very good at english, history, and philosphy and feel that those proficiencies come much more naturally to you.

I will clarify that I do not have a post-graduate degree, but I was recommended to a program because I apparently am very good at bridging gaps between disparate fields (psychology, education, and engineering). In my professional career I have found this to be very handy. It can be a boon to be exceptional at one thing, it can be a source of great opportunity and wealth to be able to understand several things very well and bridge the gaps between them.
Your opportunity at a PhD program will open doors for you to explore how you can connect your various proficiencies. You will absolutely have to work hard and the fact that you've done so in the past bodes well for you. I don't know how one could bridge mathematics with philosophy, but I don't know if I'm particular exceptional in either of those fields. You, however, might be. And you might be able to forge those bridges and advance our collective understanding in both fields forward.
As you seem to have a great opportunity before you, I strongly urge you to pursue it if you have the means to. You may find it's a dead end, but there is considerable education to be gained in failure.

Do you even have A's on PhD level? Where I am from it was pass or fail.
The idea is that at PhD level you could even grasp the material better than your teacher and expand the subject further than the course covered it.
If everything goes well, every few years a couple of the students are even supposed to do this.

I agree with others that you should try if you love it. Two things to consider -

Think about the alternative. You will never know if you could have
done it and you will probably regret quitting before you start.
It is very likely that the people think the same about you, where you are the one who is smarter and more talented. They have reason to think so! You were at the top of your class, you are in the 95% percentile. Imagine how the other 95 feel about you =P

I understand how you feel. I also love mathematics/statistics and computer science but consistently score better in the humanities with less effort. That does not mean that I have no talent, I still score better than many of my classmates in STEM fields, and I do not love the humanities in the same way. In the end you become good at what you spend time on and you want to spend time in mathematics. Do your best, decide later.


text:
How do I ask for a better grade?
The prof did not mention his grading scale in this syllabus. I got A- with 94. The School usually set the A scale to be at 93. But the professors always have the right to set his own standards (e.g. curves).
I am currently writing for a better grade. Shall I attach a university's recommended grading scale as attachment? Is it a good idea to mention that some big companys are only looking at straight A average?
Could you please let me know how to ask for a better grade?
Thank you so much. You are always helpful. Any comments are welcome.

You must not ask for a better grade.

Of course I am merely asking for "review" the grade. Everyone know what does this mean, though.

Mentioning what big companies are looking at will not come across as a request for a review, but as a request for a grade that you didn't earn. It will not be received well.

From the professors point of view there is no difference between "asking for a better grade" and "asking for a grade review". As you said "everyone knows what this means". Hence, @MassimoOrtolano's comment applies.

Maybe politely asking about his grading scale?

Have a look also at this answer and the last point of this one.

Is there anything you would have done differently during the course if the syllabus had shown the actual percentage to letter mapping?

Thanks. Why is my question getting down votes? Other questions in the same kind got upvotes instead.

@PatriciaShanahan Of course I will work harder if A=95

@Low GPA At uni you must earn things, they are not given for free. You have much better chances to get a better grade if you ask for "some extra work to do" or something like that. The question is down voted (I think) for this reason. Also it probably pisses off the professor if you ask for better grade without a major error in grading (e.g. he missed a paragraph). Usually grades are not changed unless there was a major (not minor) error in professors part.

Sit down and figure out what will make you a valuable employee, and focus on those things.  I don't think nitpicking about the difference between an A- and an A is one of the qualities and talents that a company would look for in an outstanding employee.

There is basically only one way you're likely to get your grade changed, which is if the professor made a mistake.  That does happen sometimes - I once corrected a grade under circumstances similar to what you're describing - but it's unusual.
You want to write a short message pointing out that

you think your average is 94
you got an A-

and then ask what the cut-off was for an A in this course.
And - and this is important - that's it.  Do not:

Outright ask for a better grade
Talk about how important the grade is to you or to your job prospects
Include the university's recommended scale or otherwise try to convince the professor about what the cut-off should be
Ask for extra work or another way to retroactively improve your grade.

This would be the right answer if I did not know first hand of examples where doing the "do not"s has resulted in students having their grade improved.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/