Currently, I'm looking for some sites or forums that suitable to asking about math problems like differential equations, numerical methods in MATLAB.

I've tried the MATLAB Community to ask about it, but lastly, I asked about 14th order Runge-Kutta and the code about 20th Adam-Bashfort-Moulton, and for the second time my question was not answered. Most of them just care about how to operate MATLAB in advanced programming, and not always about math.

I've tried Stack Overflow, Computational Science, Math Exchange, but my question will end up with downvotes and off-topic. And I'm afraid, some people would think I was asking for an answer for homework, even if it's not.

The following is an example of my question what I'm talking about:

Please correct my code in matlab (7th order Adam-Bashforth-Moulton for ODEs)

Where exactly can I find it?


4 Answers 4


Please correct my code in matlab (7th order Adam-Bashforth-Moulton for ODEs) is a wall of text question with no accompanying description of what you are trying to do, what you have tried and where you are stuck.

As such it needs much more focus before it is suitable for any site.

The code you present should be a code snippet only.

  • Yeah, sometimes it's hard to determine the title of my question. But, at least i hope they will read the contents of my question
    – user516076
    Dec 21, 2019 at 0:47
  • The problem with your question is principally in its body. Your title should summarize the body after you have improved that.
    – PolyGeo
    Dec 21, 2019 at 0:51
  • Ok, probably it's my mistake bcz of i didn't mentioned the detail.
    – user516076
    Dec 21, 2019 at 1:14
  • 1
    @user516076 - You should edit your question and mention the details.
    – Ramhound
    Dec 21, 2019 at 8:42

A moderator from Computational Science joined the conversation.

This question (or these types of questions) can be made on-topic on Computational Science with some efforts. We generally discourage questions that ask for "debug my code" or "how to implement X in programming language Y".

However, the community at Computational Science is always interested in helping people to learn numerical methods, ways to test them, compare and benchmark things, etc.

So, first of all, I would pose such questions very differently:

  1. I have a numerical method that I've implemented. Here is the brief math that goes into it.
  2. I test it on the following numerical example. Here is the brief math covering it.
  3. However, I don't get the results I expect. I get this; however, I expect to get that (actual numbers, convergence rate, iteration count, optimized value, whatever).
  4. What experiments would you suggest doing to find the bug? Could it be a "feature" of the method? What are the canonical examples to test my algorithm? ...etc,etc.
  5. Also, here is the minimum working code to reproduce the behaviour. This code should be cleaned of unnecessary things and comments are more readable in English.

Now, your question is not "correct my code", but how to do it and is actually about computational science.

You've got several comments on the code which I agree with: it is extremely hard to read. I would strongly suggest rewriting it in a more human-friendly fashion.

So, in general, such questions are welcome when they are presented and posed right, and are not about coding per se, but more about the numerics.


On Math SE, as I write this, there are 2,714 questions tagged "matlab", such as shown in this list. A few of them are closed. However, the rest are open, with most of them being upvoted and/or having answers.

I believe an important issue for any question about MATLAB to be well received on Math SE is that a significant, if not largest, part of the question should involve math rather than MATLAB. I've seen questions, even if they involve math in some way, basically asking people to write or debug MATLAB code for them, being closed. Note I've voted to close a few of them myself. With your particular question on Computational Science SE, as it's currently written, I suspect it would also be closed on Math SE. Nonetheless, I've seen other questions involving MATLAB, where this is more of a secondary concern & with it being primarily about the math aspects instead, being up-voted & answered.

With any site you choose to post your question, you should check on how well it'll fit within the site's purpose. Also, try to tailor & emphasize those particular aspects in your question. Finally, but likely most important, as explained in this other answer, please ensure your question is clear & well written so it'll be relatively easy for people to read & answer it.

  • Yes thanks before. English is sensitive language i think. Because some people will criticize if my english is bad. And that is my weakness.
    – user516076
    Dec 21, 2019 at 1:17
  • 2
    @user516076 You're welcome. I assume from what you've written that English is not your first language. However, even just the wording in your question there, & here, shows your English writing skills are actually quite good. I've seen & read a few questions on Math SE which are sometimes even hard to understand what they're asking for, but I, & I believe most other people also, try to understand that some people struggle with English. However, at least with your particular question, I believe the problems are more with other issues, such as in the comments people provided to you there. Dec 21, 2019 at 1:23

As @PolyGeo mentioned, your question needs improvement to be asked on any site.

With improvement you can try on Operations Research, it has a measly 5 Matlab questions because the site is new. Runge-Kutta and ABM, along with ODE, are not found, but seem on-topic.

There is OR Chat for a simple question, but it is visited infrequently; a quick question might also be answered in Mathematics Chat, but debugging Matlab might well not be a favorite. I think it's a stretch for our Economics.SE, but they do have several difference-equations tagged questions.

Stack Overflow should be OK if you follow those instructions, and since you've already asked there it would be best to go back to edit and fix that question to avoid a question ban / rate limit.

The way you wrote on Stack Overflow would have been suitable for their meta, you can ask to have it moved; or simply improve it by including a minimal example in one block (and since it's not enormously long the whole thing in a 2nd collapsed block). Their main site is not the place to 'ask if you can ask'.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .