r/ScientificComputing

▲ 2 r/ScientificComputing+1 crossposts

Can anyone help me with my Gaussian Elimination algorithm?

why is my Gaussian Elimination algorithm doesn't work, especially the second part, I made a lot more details on why I think it doesn't here https://scicomp.stackexchange.com/questions/45561/gaussian-elimination-2nd-part but I can't get it completely. can anyone help?

import numpy as np

A=np.array([[4,8,12],[3,8,13],[2,9,18]])
b=np.array([4,5,11])

def Gauss_Elimination(A,b):
    n = np.shape(A)[0]

    # 1st Part
    for k in range(n):
        pivot_element=A[k,k]
        # if pivot_element==0: ### I'll deal with this condition later
        for j in range(k+1,n):
            b[j]=b[j]-(A[j,k]/pivot_element)*b[k]
            A[j,:]=A[j,:]-(A[j,k]/pivot_element)*A[k,:]

        # 2nd Part
        x = np.zeros(n)
        x[-1]=b[-1]/A[-1,-1]
        for i in range(n-2,-1,-1):
        x[i]=(b[i]-np.sum(x[i+1]-A[i,i+1]))/A[i,i]
    return A,b, x # not necessary since it's call by reference

Gauss_Elimination(A,b)
print(A,'\n',b)
reddit.com
u/Mental_Primary_5558 — 4 days ago
▲ 21 r/ScientificComputing+4 crossposts

Комплекс Фізичних Застосунків

Усім привіт. Нарешті опублікував у Steam свій комплекс по фізиці, тож усіх прошу подивитись та добавити активності (додати у вішліст, тощо). Це проєкт, котрий коріннями уходить в далекий 2004 рік. Зараз по суті я реалізував його другу версію, в якій є 120 фізичних інтерактивних модулей. Сподіваюсь вам буде цікаво, а якщо вирішите підтримати грошима - лише для українського регіону у стимі велика знижка.

u/mischa_bayern — 5 days ago
▲ 9 r/ScientificComputing+1 crossposts

Most important coding languages for mathematical theoretical physics?

I am pursuing a dual degree in math and physics for undergrad and focusing on mathematical physics in grad school (maybe string theory but most certainly particle physics). I am going to begin learning coding languages in advance so that I can do computational physics for necessary simulations. I was wondering what the most important ones would be for this specific focus?

reddit.com
u/BinkOnBonk — 11 days ago

Is pursuing a career in Scientific Computing a good path for someone with a Computer Science background?

Hi!

I'm a Computer Science graduate and want to build a career in Scientific Computing/Computational Science. I'm considering pursuing masters in Computational Science because I really like this field, but I have some concerns.

I wanted to ask

  • If it is reasonable for someone with a Computer Science background to study Computational Science, given that I would be competing with people from Mathematics and Physics backgrounds? I feel that Computational Science is much more closer to Mathematics and Physics than to Computer Science.
  • How AI/LLM might affect this field, since it can make programming easier than it was before.
  • Are there good career opportunities in this field in the current job market?

Thanks!

reddit.com
u/Best_Fork — 10 days ago

help with picking a course for basic computational physics

i'm an undergrad physics student trying to learn the basics of scienctific computing like numpy, matplotlib and scipy (preferably in that order)- what courses can I refer to (preferably free, but I have no aversion to paid courses either). Is the 'Scipy 2019' playlist by Enthought on youtube good? It seems to be fairly detailed, open to suggestions :)

reddit.com
u/ChickenWing736 — 11 days ago
▲ 10 r/ScientificComputing+1 crossposts

How to get better at algorithms and modeling Math Equations in Code?

I’m not a beginner programmer, but I’m relatively new to scientific programming. I’ve recently started doing scientific research with a professor, and a significant part of my work involves writing simulations, modeling physical systems and mathematical equations computationally, and developing algorithms to analyze or reproduce these systems.

I’m interested in becoming much stronger at this side of programming, particularly in areas like numerical methods, computational physics, mathematical modeling, simulation, and scientific computing.

For those of you with experience in scientific programming, what would you recommend as the best way to build these skills? I’d especially appreciate recommendations for textbooks, courses, projects, libraries, or other resources that helped you make the transition from general programming to scientific/computational programming.

I’m comfortable with programming fundamentals, so I’m primarily looking for resources that go beyond the basics and focus on the actual mathematics, algorithms, and computational techniques behind scientific programming.

Any advice or recommendations would be greatly appreciated!

reddit.com
u/Positive-Stand2898 — 11 days ago

I built a NumPy/SciPy scientific computing system for reproducible numerical workflows

I’ve been building scientific-computing-system-2.0 as a NumPy/SciPy-backed environment for scientific workflows I kept recreating across different projects.

It currently exposes 535 public APIs across 52 importable names, covering numerical linear algebra, statistics, optimization, ODE/PDE/SDE work, signal processing, Monte Carlo, Bayesian methods, time series, graph methods, reliability, survival analysis, epidemiology, finance, spatial statistics, image/text processing and related areas.

The part I’ve spent the most time on is the fitting workflow.

guided-fit can take CSV data, inspect missing values, compare several model families, run repeated cross-validation, handle outliers explicitly, use measurement uncertainty when available, calculate parameter uncertainty and confidence intervals, cross-check the fitted result numerically and save the analysis to a replayable manifest with the input hash.

Current main has 1,812 passing tests and 100% branch coverage.

The validation setup also includes numerical oracle comparisons, property-based tests, fuzzing, regression checks, reproducible-build checks and CI across Linux, Windows and macOS.

There are 20 runnable scientific examples covering things like Bayesian inference, epidemic simulation, nonlinear dynamics, parameter fitting, graph analysis, signal denoising, portfolio risk, reinforcement learning, survival analysis, spatial autocorrelation, optimization and wavelets.

I also keep benchmark results with their provenance and leave slower results visible rather than treating the benchmark as a universal speed claim.

The current package also has optional CuPy GPU support, scikit-learn-compatible estimators, profiling/regression tools and optional compiled kernels for KMeans and PageRank, with NumPy fallback if the compiled path isn’t available.

I’d be interested in feedback from people doing numerical/scientific computing, especially on the API design, validation approach and which numerical areas are still missing.

GitHub:
https://github.com/Furox-Art/scientific-computing-system-2.0

PyPI / pip:
pip install scientific-computing-system-2.0

npm:
npm install scientific-computing-system-2.0

The npm package is only a thin launcher for the Python CLI; the actual scientific package still comes from PyPI.

u/furkannarkn — 9 days ago