FreeCAD: master 7c1c56a5

Author Committer Branch Timestamp Parent
abdullah wmayer master 2015-11-20 06:35:19 master a029d90a
Changeset Sketcher: Solver Debug functionality: Ability to export a subsystem

===================================================================

It allows to export the c++ code to create a subsystem with the same information as the one solved using LM/DL/BGFS.

In this commit the functionality is disabled (for production).

To enable the functionality uncomment this line in planegcs/Constraints.h:
//#define _GCS_EXTRACT_SOLVER_SUBSYSTEM_

When enabled, upon solving with LM/DL/BGFS, the c++ code to generate the subsystem is added to a subsystem.txt that is created in the FreeCAD
execution directory.

Note that the file is created in append mode, so it will append all normal/redundant solvings until the file is deleted.

The resulting code can be directly pasted into a project similar to:
https://github.com/abdullahtahiriyo/Eigen_LUPiv_Convergence

Such a project only has libeigen as external dependency.
mod - src/Mod/Sketcher/App/planegcs/Constraints.h Diff File
mod - src/Mod/Sketcher/App/planegcs/GCS.cpp Diff File
mod - src/Mod/Sketcher/App/planegcs/GCS.h Diff File
mod - src/Mod/Sketcher/App/planegcs/SubSystem.cpp Diff File
mod - src/Mod/Sketcher/App/planegcs/SubSystem.h Diff File