Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link

In Mathematica, this does not affect performance because copying does not take place most of the time. To put it simply, Mathematica implements copy-on-demand: it creates a copy of the data structure only if it is modified. Please see this answer for a more detailed explanation:

Does passing a variable with a large amount of data cost a lot of memory and time in Mathematica?Does passing a variable with a large amount of data cost a lot of memory and time in Mathematica?

In Mathematica, this does not affect performance because copying does not take place most of the time. To put it simply, Mathematica implements copy-on-demand: it creates a copy of the data structure only if it is modified. Please see this answer for a more detailed explanation:

Does passing a variable with a large amount of data cost a lot of memory and time in Mathematica?

In Mathematica, this does not affect performance because copying does not take place most of the time. To put it simply, Mathematica implements copy-on-demand: it creates a copy of the data structure only if it is modified. Please see this answer for a more detailed explanation:

Does passing a variable with a large amount of data cost a lot of memory and time in Mathematica?

Source Link
Szabolcs
  • 236.5k
  • 31
  • 641
  • 1.3k

In Mathematica, this does not affect performance because copying does not take place most of the time. To put it simply, Mathematica implements copy-on-demand: it creates a copy of the data structure only if it is modified. Please see this answer for a more detailed explanation:

Does passing a variable with a large amount of data cost a lot of memory and time in Mathematica?