dmorse / pscfpp

Polymer Self-Consistent Field Theory (C++/CUDA version)
https://pscf-home.cems.umn.edu
GNU General Public License v3.0
25 stars 20 forks source link

Adding IntraCorrelation (intra folder) and LrPostAmCompressor #176

Closed chen7545 closed 2 months ago

dmorse commented 2 months ago

Kexin, I do not understand why you added an IntraCorrelation object as a dynamically allocated member of the System. I think it would be a better design if any Compressor class either (1) owns a private IntraCorrelation object, or (2) Is a subclass of IntraCorrelation. Between these two options, I prefer (1) - just have the compressor own a private object of this type to do the required calculations, but don't change the public interfaces of either the Compressor base class or the System. This functionality seems much too specialized to be exposed in the public interfaces of either of these classes - try to encapsulate and hide implementation details.

chen7545 commented 2 months ago

It was designed so that the intraCorrelation can be used for both compressors and analyzers. Since linear response analyzer has been deleted, I will modify it.