Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [computational-complexity]

The tag has no usage guidance.

1
vote
1answer
52 views

Cutting digits of a number without approximation:

I am evaluating an exponential and I end up with the following result: $1.4497788553129478854329$ Is there a command on Mathematica that allows me to cut my result without approximating it? I would ...
1
vote
1answer
35 views

Finding ponts closer to each other than a given distance

As a working example let's assume that we are given a list of points in the unit square (say by RandomVariate[UniformDistribution[{0, 1}], {20, 2}]). I want to ...
1
vote
1answer
105 views

SparseArray: accesing nonzero row and column entries

I have an enormous $m\!\times\!n$ sparse matrix $d$ with $l$ nonzero entries, stored as d=SparseArray[{{i1,j1}->w1,...,{il,jl}->wl},{m,n}];. How do I access ...
6
votes
2answers
793 views

Is there a way to do Quantum Computing in Mathematica notebook?

I saw 2 efforts in that direction: WSS17 and WSS16, but I am not sure if there is something in the latest Mathematica that actually allows users to simulate quantum gates. Can anyone please point me ...
0
votes
0answers
34 views

Why does this ArgMax take so long to compute?

I have the following code which is supposed to return me the arguments for $l1,k1$ that maximize the function $fsub$, subject to constraints. I need the answers algebraically as functions of the other ...
10
votes
2answers
439 views

Simplify expression: overcome a barrier in the complexity function

I would like to simplify x=n[a] f[b, a] + f[a, b] using 2 rules ...
1
vote
0answers
76 views

How maximaze very complex problem in a few hours using some server?

I need to execute a code that runs a maximize function built-in function with symbolic variables. The problem is that my computer has not enough memory (has 4 GB of ...
0
votes
0answers
114 views

Finding Option Value in American Options

I want to find the Option Value in American Options. I basically want to replace this code if possible ...
1
vote
0answers
33 views

Measuring space complexity? [closed]

I like using GeneralUtilities function BenchmarkPlot for estimating time complexities, is there something similar for ...