circuitjs1 icon indicating copy to clipboard operation
circuitjs1 copied to clipboard

Circuit Lagging

Open renanbertolazo opened this issue 4 years ago • 6 comments

Hi, is there any way to make large circuits make less lag? I'm doing some large circuits but is very laggy and i can't even use them.

renanbertolazo avatar Sep 14 '21 04:09 renanbertolazo

There are some tricks you can use. Can you send one of the circuits?

pfalstad avatar Sep 15 '21 23:09 pfalstad

Prova8.circuitjs.txt this one and this one Ram_16x4.circuitjs.txt

renanbertolazo avatar Sep 16 '21 00:09 renanbertolazo

Those are some big circuits. I don't have any tricks that would help, I don't think. I had some ideas to optimize large circuits like this, but I'm not sure when I'll get to it.

pfalstad avatar Sep 16 '21 18:09 pfalstad

Ok sr, thank you very much :)

renanbertolazo avatar Sep 16 '21 19:09 renanbertolazo

I am having similar performance issues with my circuit.

Eugene2003 avatar May 25 '23 07:05 Eugene2003

I used the file "Prova8. circuitjs. txt" from the questioner of this issue for testing,For large circuits, use the default step size of 5 μ s. The calculation is slow, even if the step size is adjusted to 500 μ s. Still slow, use sparse matrix and adjust step size to 500 μ s. The performance improvement for large circuits is very obvious, and I may have forgotten to tell you that large circuits need to adjust the step size to 500 μ s. Even larger step sizes can be adjusted according to the size of the circuit,

A set of test results Refresh Time (Normal LU Decomposition) Refresh Time (Sparse Matrix LU Decomposition) Matrix Size

2167 milliseconds 414.0 milliseconds 1232 7324 milliseconds 532 milliseconds 1592 32102 milliseconds 618 milliseconds 2352 No test 1441 milliseconds 3511

Using a better sparse matrix structure can be faster and support larger matrices. Below are the test results: Refresh Time (Sparse Matrix LU Decomposition) Matrix Size

400ms 24470/22100 430ms 48870/44200 460ms 73270/66300 550ms 122070/110500

H-Dynamite avatar Jan 26 '24 04:01 H-Dynamite