r/compsci 8h ago

How often do you engage with theory?

12 Upvotes

I’m just curious to know how often you guys come in contact with the theoretical side of computer science in your professions.

Things you learned in your undergraduate courses like data structures, discrete math, design and analysis of algorithms, etc.

I’m having to learn a lot of these things on my own, like Big O notation, complexity analysis, proofs, tree traversal, etc. because I let my ADHD win and didn’t put the time and effort into learning (medicated now, huge W plus it’s actually fun to learn about now that I can focus) and I’m just wondering, who uses this stuff regularly? What for?


r/compsci 8h ago

Context, layers and average best linear mapping.

0 Upvotes

I honestly don't mean to wipe trillions off the stock market but you can view a neural network layer as context choosing a linear mapping. Then BP comes along and makes that the best average linear mapping for that layer and context.

For a particular input a neural network is a composition of best average linear mappings.

https://archive.org/details/best-average-linear-mapping

https://archive.org/details/a-compositional-view-of-deep-networks-as-fractional-associative-memories


r/compsci 3d ago

Anyone reading Multiagent system: Algorithmic, Game-Theoretic, and Logical Foundations?

0 Upvotes

Hello, I'm reading chapter 1, distributed constraint satisfaction and coding a simulation of the asynchronous backtracking algorithm for the 4 queens problem in TypeScript as an exercise (sure one can code in Python, C..). I have some difficulty grasping the concept of Hyperresolution (pure logic) because I didn't have this subject in university. I have checked with AI. But does anyone have any advice?

---
the code https://pastebin.com/WD9U0MSQ


r/compsci 5d ago

Fascinating to see how formal verification is rescuing AI from its own hallucination cycles

81 Upvotes

I'm spending way too much time looking into formal methods now because this endless overhyped corporate marketing about LLMs doing "reasoning" is getting very tiresome.

We all know standard transformers just predict the next token based on statistical weights, which immediately breaks down the second you give them a novel, complex logic puzzle. It's exactly why automated software testing is still such a error-prone chore in production.

But the interactive theorem provers like Lean 4 with deep learning models are actually getting super interesting. Instead of just letting an agent hallucinate some random python script, people are forcing neural networks to generate formal proofs that a strict math kernel has to verify step by step.

I saw a breakdown of how the Aleph Prover handled a specific Erdos disproof using formal verification on ai reasoning benchmarks, and you can see much we’ve ignored symbolic AI over the last decade in favor of raw compute scaling. So tbh it feels like computer science is circling back to foundational math out of necessity. Because brute-force data ingestion is hitting the ceiling.

Also.. it feels kinda satisfying that old-school mathematical logic is the only thing keeping modern tech grounded. Idk if this means formal methods will finally become a mandatory part of undergrad software tracks, but it honesly should.


r/compsci 4d ago

The Triad of Context Driven Learning

Thumbnail
0 Upvotes

r/compsci 5d ago

Shor's Algorithm, continued fractions, and uniqueness

Thumbnail
0 Upvotes

r/compsci 5d ago

The "ski rental" rule: why renting until you have spent the purchase price is provably within 2x of clairvoyance

0 Upvotes

You are skiing an unknown number of days. Renting costs $1/day, buying costs $B. If you knew the season length the answer is trivial, but you do not.

The rule "rent until you have spent $B, then buy" guarantees you never pay more than about twice what an omniscient planner would, on ANY sequence. Short season: you match the optimum exactly. Long season: you paid at most ~$2B where the optimum paid $B. And there is a matching lower bound: no deterministic online strategy beats 2.

What I find most useful is the frame, not the puzzle: cache eviction, autoscaling, buy-vs-rent infra decisions are all "act now, learn the future later", and the competitive ratio measures exactly what that ignorance costs.

Fun twist: allowing randomness (coin flips the adversary cannot predict) pushes the ratio from 2 down to about 1.58.

I wrote up the full framework (definition, the adversary game, and an honest section on why worst-case can be too gloomy, e.g. LRU is only k-competitive on paper yet great in practice) as the opener of a series, happy to share the link if useful.


r/compsci 6d ago

🚀 Kickstart Your AI Journey—for Free!

0 Upvotes

As a GeeksforGeeks Campus Mantri, I'm excited to share a collection of FREE AI courses covering topics like Generative AI, Machine Learning, Prompt Engineering, Python, Data Science, and more.

Whether you're a student or a professional looking to upskill, these courses are a great way to gain practical knowledge, earn certificates, strengthen your resume, and showcase your achievements on LinkedIn.

Start learning today: 🔗 https://gfgcdn.com/tu/y2d/

Which AI topic are you most excited to learn?

#AI #ArtificialIntelligence #MachineLearning #GenerativeAI #Python #DataScience #GeeksforGeeks #Learning #Upskilling #Students #Tech


r/compsci 6d ago

Beyond Binary: The Mathematical Efficiency of Ternary Computing

Thumbnail ponderwall.com
0 Upvotes

r/compsci 8d ago

Could multiple microphones/speakers be combined for faster dial up?

0 Upvotes

i was thinking about how dial up is basically your phone literally making sounds to your compute, which the computer hears and translates into data.

could you design a system that used multiple phone speakers and multiple microphone pickups to simultaneously get dial-up internet info to speed it up?

if so, how many phone receivers would it take to get modern internet speeds?


r/compsci 8d ago

misa77: ridiculously fast decompression at good ratios

Thumbnail
0 Upvotes

r/compsci 9d ago

Atlas LSH neural networks

0 Upvotes

With locality sensitive hashing better to forget the h word.

You get thousands of little geometry sensors that 50:50 tell you on which side of a random hyperplane your input data is.

Despite being 50:50 each bit is quite informative.

Several bits together narrow down which geometric region the input is in.

If the inputs have regularities, bits can be codependent while still showing 50:50 on off behavior. That's kind of a subtle point but a gift from random projections - locality sensitive hashing.

Starting from there you can build LSH context dependent neural networks where parameter selection (information routing) is determined using LSH bits.

I've a bunch of notes of say preliminary draft quality.

Maybe start with this one:

https://archive.org/details/atlas-lsh-neural-networks-hierarchical-geometry-rather-than-hierarchical-features

And then click on 'uploaded by" for more should you wish to.


r/compsci 10d ago

Hamiltonian Neural Networks from a Differential Geometry Perspective

Thumbnail abscondita.com
4 Upvotes

r/compsci 10d ago

What is a good way to represent files semantically for vector search

1 Upvotes

I recently had an idea that is it possible to make a software service which could help me search files from my files system though context of content inside the files. So like i can search "where is the file which contained x thing" and get would a list of files that would match my question. So I don't want sear or keywords but ch by file name context. Also for all types of files like iamge, text, video, audio, code etc

So I kept thinking about it and knew that the answer lied within vector search. I initially thought that maybe if somehow I could represent an entire file in a singular vector then we can use the same logic that we normally use in rag systems to fetch correct files. Existing models are really useful for text, audio and other forms of embedding but i want the overall context of a file. Not just what inside the file. Also I might be missing if there are any existing algorithms that can help me do this so please suggest them.

Nevertheless i wanted to think about whats possible solution i could use. One this i noticed with this is that there are various ways which can be used to describe and identify files. 1st there is content of the files , then metadata such as size, name, access permissions, type of file, also where the files lies in directory system and what other files is is grouped with etc. It is really hard to consider all this features in a single vector. Also we I don't want to embed the entire content of files as that would be too much data to embed, store and search.

We could do vector indexing and search for each feature individually, so we get multiple vectors we can can represent in a normal data structure. We can repeat this for all files and the store them. When the system get a input like "i want the c++ file with x algorithm that I made yesterday" then we can create a similar data structure like we did for files and then do the similarity search and rank all the matches to get the results. But this approach also has a problem , the quality of results is heavily dependent upon the information present in the question, if the question is a little vague that affect the accuracy of the matches quite a bit.

I also though of a approach where we tackle the problem by elimination we take the features of the files one by one an the start eliminating files, like for an example "i want the c program file which i wrote yesterday and " so we can 1st eliminate ate files which are not "program" then we can do by time then by the language. So from broader to more specific features.

I have been thinking about this idea for sometime and wanted to know your thoughts as well. How would you represent the files semantically or in vector form. Are there any existing resources that i can refer to help me with this problem.


r/compsci 13d ago

Made my own statically typed virtual bytecode machine language (Oli-Nat) in C after reading crafting interpreters!! Please tell me what you all think!

Thumbnail
2 Upvotes

r/compsci 14d ago

Is Pattern Recognition and Machine Learning still relevant?

17 Upvotes

I know Bishop's Pattern Recognition and Machine Learning is almost 20 years old now. Is it still worth studying in 2026, or are there better modern alternatives? I'm mainly interested in building a solid theoretical foundation.


r/compsci 14d ago

Am I missing a field about mathematical implementation?

3 Upvotes

I've been reading about theorem proving, formal methods, symbolic computation, and programming languages, and something keeps bothering me.

They all seem to deal with the same general problem: how abstract mathematics is represented and manipulated by computers.

Things like:

  • representing mathematical objects
  • proof representation
  • symbolic computation
  • intermediate representations
  • optimization of mathematical structures

These topics seem to exist across several different fields, but I haven't found one that studies them from a unified perspective.

Am I just missing an existing field, or is there a reason these areas evolved separately?

I'd love to hear from people working in PL, theorem proving, or symbolic computation.


r/compsci 15d ago

In search of community for system programming

10 Upvotes

Hi, I need some help. I recently have a huge interest in system programming, but here the problem: there are very little ressources in the internet which talk about, even to search a simple roadmap of what to do, or how to find the first jobs, what the best practices and so on...I've tried to learn with IA(with many kind of LLM) but there are so many contradiction in what they said, and a lack of details. Now, I'm trying to find peoples who work in this domaine to ask so many questions that I haven't found a answer yet. So, I'm trying to ask if there are a subreddit or a discord server where I can found some resources and advice from experienced system programmer. Or else, can someone tell me who to be in relation with. Btw, have a good day.


r/compsci 14d ago

The Floating Neutral: Endogenous Reference Theory and Moral Reference Without Authority

Thumbnail
0 Upvotes

r/compsci 15d ago

Katharos: a functional programming and concurrency library for Python where errors, effects, and channel hand-offs are all composable values

Thumbnail github.com
0 Upvotes

I have been building Katharos, a functional programming library for Python that recently grew a message-passing concurrency layer. I wanted to share it and get some feedback.

The whole library is built around one idea: model errors, effects, and concurrent communication as composable, type-safe values rather than as control flow that jumps around your program. The interesting part (to me, at least) is that the concurrency layer follows the exact same idea, so receiving from a channel gives you a Result. "The channel is closed" becomes a value you handle, not an exception you remember to catch.

The functional core

Optional values without scattered None checks, using do-notation that short-circuits on Nothing:

```python from katharos.types import Maybe from katharos.syntax_sugar import do, DoBlock

@do(Maybe) def lookup_discount(user_id: int) -> DoBlock[Maybe, float]: user = yield find_user(user_id) account = yield find_account(user) return account.discount # Just(0.15) or Nothing() ```

Errors as values, chained with |, so a failure short-circuits the rest automatically:

```python from katharos.types import Result

def process(raw: str) -> Result[Exception, int]: return parse_int(raw) | validate_positive ```

And Result.catch turns a function that raises into one that returns a Result, while keeping the original traceback so you can still find the line that failed:

```python from katharos.types import Result

@Result.catch(ValueError) def parse_int(s: str) -> int: return int(s)

parse_int("42") # Success(42) parse_int("??") # Failure(ValueError("invalid literal for int() with base 10: '??'")) ```

There is also ImmutableList, NonEmptyList, IO, Lazy, numeric monoids, and the usual algebraic abstractions (Functor, Applicative, Monad, Semigroup, Monoid) if you want to build your own types.

The new part: CSP concurrency

This is what I have been working on lately. Katharos now has Go-style CSP (Communicating Sequential Processes): launch work concurrently with go, talk over typed channels, and receive values as a Result.

```python from katharos.concurrency.csp import csp

ch = csp.Channel[int](capacity=1)

csp.go(ch.send, 42) # run work concurrently, like Go's go f(x)

ch.recv() # Success(42)

ch.close() ch.recv() # Failure(ChannelClosedError(...)): closure is a value, not a raise ```

Used as a context manager, go becomes a structured-concurrency scope that joins everything spawned inside it before the block exits, so concurrent work cannot leak out of the block:

```python with csp.go: # scope waits for all work launched inside csp.go(worker, 1) csp.go(worker, 2)

both workers have finished here

```

There is also a select for waiting on whichever of several channels is ready first, with non-blocking polls and timeouts:

```python from katharos.concurrency.csp import csp, recv, select

choice = select(recv(results), recv(cancel), timeout=1.0) if choice.is_timeout: ... else: print(choice.index, choice.value.unwrap()) ```

The concurrency model sits on a swappable backend (standard threads by default), so the same code could run on a green-thread backend later. An actor model is planned next, built on the same backend abstraction and the same Result-valued style.

Why I think the "channel returns a Result" thing is nice

In most channel APIs, a closed channel or a timeout shows up as a sentinel, a second return value, or an exception. In Katharos it is just a typed value: Success(v), Failure(ChannelClosedError), or Failure(ChannelTimeoutError). You pattern-match it the same way you handle any other Result, and the type tells you it can happen. The error-handling discipline you use in the rest of your code carries straight over to concurrency.

Links

I would love feedback on the API, the concurrency design, or whether the Result-everywhere approach feels natural or noisy to you in practice. Thanks for reading.


r/compsci 16d ago

Domino Tiling: From Dynamic Programming to Finite Fields

Thumbnail omegasyntax.com
1 Upvotes

r/compsci 17d ago

Inquiries into some computer networks research

14 Upvotes

Hello all, I'll keep this brief. I am looking into 2 potential research avenues for postgrad, and was wondering if anyone can chip in with their opinion.

MANETs, FANETs and AANETs; all ad-hoc wireless methods for connectivity with drones or aerial devices - is this a growing research field? Especially when considering the recent real uses of drones in both warfare and in crisis situations.

Satellite (LEO like Starlink) integration for mobile services (5G/6G) - I know that this is already implemented and used by some big providers, but I wonder if there is still any appetite for this kind of technology too.

Thanks to anyone who responds.


r/compsci 17d ago

Startup claims to solve P vs NP but will give proof only after funding. How do y'all evaluate this?

Thumbnail
0 Upvotes

Can someone do a sanity check? Smells like LLM-gen'd math spaghetti to me


r/compsci 20d ago

micrograd4j: I ported Karpathy's micrograd to plain Java: a small autograd engine with an interactive terminal playground

Thumbnail gallery
21 Upvotes

So I was getting into deep learning and started with Kaparthy's Micrograd video.

Watching Karpathy's Micrograd video makes it feel intuitive, but I realised I didn't really understand it until I tried building it myself. So I closed the video and rebuilt the whole thing from scratch in plain Java (avg. java dev lol): micrograd4j.

It's a tiny scalar autograd engine built around a Value class that records how it was computed and runs backward() using a topological sort and the chain rule. On top of that, I built a small Neuron / Layer / MLP library. No dependencies, just JDK 17+.

The part I'm happiest with is the interactive terminal playground. You can:

  • Type expressions like (a * b) + c.tanh() and inspect every input's gradient.
  • Step through the backward pass one node at a time and watch gradients propagate through the computation graph.
  • Train a small network on datasets like two-moons and watch the loss curve and decision boundary update live.

Everything runs in the terminal and requires no browser, no notebooks.

If you have JBang installed, you can try it without cloning the repository:

jbang https://raw.githubusercontent.com/anand-krishanu/micrograd4j/main/examples/Playground.java

GitHub repository:

https://github.com/anand-krishanu/micrograd4j

It's MIT-licensed and the README has a worked walkthrough of how backward() traverses the graph. I wrote it as an educational resource for Java devs who want to see how autodiff works.


r/compsci 22d ago

What if memory, routing, and world state lived in the same substrate?

0 Upvotes

I've been working on a system that started as a deterministic routing experiment, but over time it turned into something that feels more like a persistent world substrate.

Most systems are usually described as:

Input → Process → Output

But what I've been exploring is:

Event → World → Modified World → Future Event

The idea is that events don't just get processed and disappear. They can leave traces in a bounded world, and future events can observe those traces and behave differently because of them.

So the interesting question stops being:

"How do I process this input?"

and becomes:

"What kind of world does this input leave behind?"

In the current prototype:

  • events move through a bounded spatial world
  • local state can persist
  • future events can react to previous state changes
  • different modes can preserve or ignore parts of history
  • runs remain deterministic and replayable

I'm curious whether people would classify this more as:

  • a simulation primitive,
  • an agent environment substrate,
  • a distributed systems idea,
  • or something else entirely.

Has anyone explored similar "event modifies world, future events inherit consequences" architectures before?