Editing Python Solution to Dimension Tracking
Jump to navigation
Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | |||
− | |||
− | |||
− | |||
= The Problem = | = The Problem = | ||
Line 11: | Line 7: | ||
* Design decisions. | * Design decisions. | ||
− | You more or less need some notes to keep track of this stuff. Some of this may be paper sketches, paper notes, and digital documents ( many may choose spreadsheets ). I find spreadsheets to be very error prone so I looked for a python solution. The very simple version of this is shown in: [[FreeCad Gear Box]] This has now evolved, and this document will describe the solution. For the actual code contact: [[User:Russ_hensel]] | + | You more or less need some notes to keep track of this stuff. Some of this may be paper sketches, paper notes, and digital documents ( many may choose spreadsheets ). I find spreadsheets to be very error prone so I looked for a python solution. The very simple version of this is shown in: [[FreeCad Gear Box]] This has now evolved, and this document will describe the solution. For the actual code contact: [[User:Russ_hensel]] |
+ | |||
= A Python Solution = | = A Python Solution = | ||
Line 20: | Line 17: | ||
This class holds a single dimension. Of course you can just go: a_dimention = 22. What is wrong with that? This dimension has a name and a value. What it does not have is units or a type that may help distinguish between pure numbers ( teethe on a gear ), angles, and linear dimensions. Also I have upgraded the class so that it does easy unit conversions and is easy to print. | This class holds a single dimension. Of course you can just go: a_dimention = 22. What is wrong with that? This dimension has a name and a value. What it does not have is units or a type that may help distinguish between pure numbers ( teethe on a gear ), angles, and linear dimensions. Also I have upgraded the class so that it does easy unit conversions and is easy to print. | ||
− | Here is what you might get when you print a PartDimension | + | Here is what you might get when you print a PartDimension |
<pre> | <pre> | ||
Line 31: | Line 28: | ||
</pre> | </pre> | ||
− | + | === === | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
+ | == == | ||
[[Category:FreeCad]] [[Category:Python]] | [[Category:FreeCad]] [[Category:Python]] |