View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000800 | Sketcher | Feature | public | 2012-07-19 14:41 | 2015-10-06 11:48 |
Reporter | scopaev | Assigned To | logari81 | ||
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Product Version | 0.12 | ||||
Fixed in Version | 0.16 | ||||
Summary | 0000800: Formula/Equation Based Constraints | ||||
Description | The ability to use formulas/equations to control sketcher dimensions. The ability to add a custom Label Name to the dimension lines that can be used in the equations. | ||||
Tags | constraints, equation, formula | ||||
FreeCAD Information | |||||
related to | 0001437 | closed | FreeCAD | Global parameters | |
has duplicate | 0001098 | closed | abdullah | FreeCAD | Add ability to use variables and forumulas |
related to | 0001174 | closed | FreeCAD | Allow user to input simple mathematical expressions when setting values to constraints. | |
related to | 0001711 | closed | File formats | global data variables for using in constraints | |
related to | 0002250 | closed | yorik | File formats | global data variables for using in constraints |
|
This feature should have a larger scope than sketcher. |
|
tanderson, what larger scope did you have in mind? |
|
I would think anything that takes a feature parameter should have the same ability. I think it is also useful to tie parameters/variables to assembly, sub-assembly and project scopes. |
|
Yes please. I very much agree on making every parameter accept formulas and be easily accessible from other formulas. Maybe start in the part design wb, and make the pad lenght etc. accessible in such a way. With some small additions to the possible constrains, this would enable truly parametric and complex modelling. A natural extension to this would be a way to mark some values as external input, and autogenerating a gui form, a kind of a part factory. Maybe the constrain solver could be used somehow to allow overlapping input constrains, such that only a fraction of the marked input values are needed. Maybe this needs a separate issue? Challenges I foresee: * The choice of language for the formulas? Sandboxed python (hard, see pypy), an existing math->python translator or a custom one with a limited list of functions? * Cyclical references. Pythons recursion limit can be set low enough? |
|
I see somebody will try to tackle this: http://forum.freecadweb.org/viewtopic.php?f=10&t=7425 Just some additional info there actually is solution available in FreeCAD ATM that allows setting relations between datum constraints and object properties. It is called Spreadsheet PropertyController. Sketch constraints are now exposed as properties and that adds additional support but for this latest part i guess some changes would be needed to get full support: http://www.freecadweb.org/tracker/view.php?id=1703 Bottom line this feature already exist in FreeCAD and this feature request could be marked as solved/implemented. The feature itself i guess needs more polishing and should be more talked about because i am guessing a lot of FreeCAD users are not aware it exists. Relevant links: http://forum.freecadweb.org/viewtopic.php?f=10&t=7425#p60112 http://www.freecadweb.org/wiki/index.php?title=Spreadsheet_Workbench http://www.freecadweb.org/wiki/index.php?title=Spreadsheet_PropertyController |
|
And it somebody will test this it took me a while to understand this: "Target Property: The name of the property to control, or the number of the datum-based constraint" User actually has to count datum constraints and input the number of its position. But it does work! Therefore i proposed Spreadsheet PropertyController should not tackle with sketch directly any more but to take datum constraints from sketch properties (feature was just implemented): http://www.freecadweb.org/tracker/view.php?id=1703 This would be easier as user could rename constraint for example to Angle and then in Spreadsheet PropertyController just input Angle Under Property Name (Target Property) instead of current situation where the number of datum constraint must be provided (but the number can easily change if one of the constraints before it gets deleted). |
|
I won't reopen this bug report to add small note: http://www.freecadweb.org/tracker/view.php?id=1703 I tested the change and i can confirm it works! I wanted to update this on the FreeCAD Wiki but i would have to restore password and i newer edited wiki in the first place and if somebody else finds the time this could be added: http://www.freecadweb.org/wiki/index.php?title=Spreadsheet_PropertyController "Target Property: The name of the property to control, or the number of the datum-based constraint" Changed to something like: "Target Property: The name of the property to control, or the number of the datum-based constraint. If datum-based constraint is named the datum-based constraint name can be used instead of the number." Infographic probably could help new users when learning to use this feature: http://www.freecadweb.org/tracker/file_download.php?file_id=804&type=bug But i doubt it complies with FreeCAD Wiki standards regarding images. Small hint when working with spreadsheet to define relations: set Windows mode to Tile or Cascade first and it becomes easy and fun thing to do. And spreadsheet in the end is (one of the possible) very powerful way to tackle this area. Cheers and for all devs lately expressing interest in this area good luck! |
|
Expressions have been implemented: http://forum.freecadweb.org/viewtopic.php?f=10&t=8802&start=190 |
Date Modified | Username | Field | Change |
---|---|---|---|
2012-07-19 14:41 | scopaev | New Issue | |
2012-07-19 14:42 | scopaev | Tag Attached: constraints | |
2012-07-19 14:42 | scopaev | Tag Attached: equation | |
2012-07-19 14:42 | scopaev | Tag Attached: formula | |
2012-08-06 18:43 | logari81 | Status | new => assigned |
2012-08-06 18:43 | logari81 | Assigned To | => logari81 |
2012-09-19 22:44 | tanderson69 | Note Added: 0002407 | |
2012-09-20 13:09 | pperisin | Note Added: 0002410 | |
2012-09-20 17:34 | tanderson69 | Note Added: 0002412 | |
2012-09-26 17:18 | drayko | Note Added: 0002427 | |
2014-02-21 12:58 | shoogen | Relationship added | related to 0001174 |
2014-02-23 18:51 | shoogen | Relationship added | related to 0001437 |
2014-08-19 02:09 | normandc | Relationship added | has duplicate 0001098 |
2014-08-21 16:04 | triplus | Note Added: 0004983 | |
2014-08-21 16:17 | triplus | Note Added: 0004984 | |
2014-08-23 15:16 | triplus | Note Added: 0004995 | |
2014-08-23 15:18 | triplus | Note Edited: 0004995 | |
2014-08-25 13:24 | wmayer | Relationship added | related to 0001711 |
2015-10-06 11:48 | abdullah | Note Added: 0006478 | |
2015-10-06 11:48 | abdullah | Status | assigned => closed |
2015-10-06 11:48 | abdullah | Resolution | open => fixed |
2015-10-06 11:48 | abdullah | Fixed in Version | => 0.16 |