Hi,
I am testing 0.20.2 and latest weekly here. I have named constraints in my test Sketch and trying to solve pythagoras here (probably I could do this without expressions as well but do not know how).
When I give formula "Sketch003.Constraints.bottom_big_radius", the constraints is used (Picture 1). When I use Sketch003.Constraints.bottom_big_radius*Sketch003.Constraints.bottom_big_radius or pow(Sketch003.Constraints.bottom_big_radius,2) (Picture 2 and 3), I get message: "Unit mismatch between result and required unit". How could I prevent this happening?
Thanks a lot for help!
Picture 1:
Picture 2:
Picture 3:
How to multiply/pow constraints in formulas ?
Forum rules
and Helpful information
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help
Also, be nice to others! Read the FreeCAD code of conduct!
Also, be nice to others! Read the FreeCAD code of conduct!
-
- Veteran
- Posts: 3111
- Joined: Thu Sep 24, 2020 10:31 pm
- Location: Hawaii
- Contact:
Re: How to multiply/pow constraints in formulas ?
If you multiply two lengths together the result has units mm^2 To correct this divide the result by 1 mm.
Re: How to multiply/pow constraints in formulas ?
Hi,
Ah excellent. Great thanks! I just should have written the whole equation with sqrt included and the units would be correct after that.
Thanks very much for the answer!
Ah excellent. Great thanks! I just should have written the whole equation with sqrt included and the units would be correct after that.
Thanks very much for the answer!
- Shalmeneser
- Veteran
- Posts: 9475
- Joined: Wed Dec 23, 2020 12:04 am
- Location: Fr
Re: How to multiply/pow constraints in formulas ?
- Attachments
-
- Capture d’écran 2023-02-01 213510.jpg (48.42 KiB) Viewed 520 times
Re: How to multiply/pow constraints in formulas ?
Please also read Expressions.