Out of Memory Sparse Matrix

The right solution is to quote your code: PSA: how to quote code with backticks

I’ve edited your post to fix this. Welcome to the Julia Discourse forum!

Also, it would be easier to help you if you posted a minimal example that is runnable (as opposed to using lots of undefined symbols like Kx and Ay): Please read: make it easier to help you