homalg-project / CAP_project

CAP project -- Categories, Algorithms, and Programming
https://homalg-project.github.io/docs/CAP_project-based/
24 stars 18 forks source link

Remodel derivation mechanism #144

Closed sebasguts closed 1 month ago

sebasguts commented 6 years ago

Since several issued with the derivation mechanism popped up recently, there should be a complete remodeling of the derivation mechanism. The following topics should be adressed:

To adress those changes, the following changes in the CAP kernel are necessary:

This issue is meant to track progress on this topic, and will be updated in the next few days, while I am working on implementing this feature.

sebastianpos commented 6 years ago

Let me explain how the final derivations are used at the moment and why they have to be enhanced.

When you take a look at the final derivations in the DerivedMethods.gi file, you will see basic operations like IsomorphismFromFiberProductToKernelOfDiagonalDifference. These are natural isomorphisms between a universal object and a concrete construction of this universal object. By the CAP's final derivation mechanism, these natural isomorphisms are set to the identity assuming the user called Finalize and did not provide his own construction of this universal object. In this way, CAP's final derivation mechanism is able to coherently deal with interdependencies of derivations. In particular, the derivation of ProjectionInFactorOfFiberProduct and UniversalMorphismIntoFiberProduct via direct products and equalizers (suggested in this pullrequest) could also be dealt with in this way by introducing a basic operation like IsomorphismFromFiberProductToEqualizerOfDirectProductDiagram and using it within the implementations of ProjectionInFactorOfFiberProduct and UniversalMorphismIntoFiberProduct.

However, a problem arises when there simply is no such natural isomorphism, e.g., in the case of weak universal objects. I can derive a weak fiber product by employing lots of different constructions, like 1) using FiberProducts, 2) using DirectSums and Kernels, 3) using DirectSums and WeakKernels,

and all of these possible constructions can yield non-isomorphic realizations of weak fiber products. There simply are no natural isomorphisms mediating between these different constructions of weak fiber products. However, I want to be able to teach CAP all of these 3 derivations. This is why an enhancement is needed.

zickgraf commented 1 month ago

Once https://github.com/homalg-project/CAP_project/pull/1699 is merged, I think this issue can be closed, after more than 6 years!

Changes implemented over the last years:

Changes not implemented:

In particular, there is no mechanism for finding a maximal tree of derivations. However, such a mechanism would come with its own drawbacks:

Summing up, I think the current state of the derivation mechanism is future-proof and covers the original problems given in this issue well enough to close this issue as completed.

mohamed-barakat commented 1 month ago

Wonderful, thank you very much.