Benjamin Nauck
19fa91253f
Remove octal in expressions when there's a leading zero
2024-11-22 11:47:18 -05:00
Connor Worrell
f552b72539
[App] Expression parser allow multi unit inputs (2'2")
2023-05-31 19:49:28 -04:00
CarlOlson
926c1253af
update expression grammar to handle parens around cond
2023-03-26 18:48:59 +02:00
Uwe
b41776d077
[Core] disable the the unit Oersted
...
- is not feasible for practical usage and (was up to now not used, thus no consequence)
moreover, Oersted is a cgs unit while we use SI units, thus also not suitable for FEM, only makes problems for magnetization
2023-02-08 19:59:36 +01:00
Uwe
0a4b860d66
[App] [skip ci] add info for expression lexer generation
2023-02-08 06:34:59 +01:00
0penBrain
78e1174018
Core: partially revert 4ab37fc that introduced composed units
...
Parser shall only deal with atomic units or it breaks other composed units
Fixes #6735
2022-04-13 03:45:39 +02:00
Preslav
4ab37fc0ca
Added stiffness units to FreeCAD [mN/m, N/m, kN/m, MN/m]
2021-08-16 12:27:41 +01:00
donovaly
bcc669b930
[Base] add electrical conductivity
...
- this is necessary to perform electrodynamics simulations. Since the typical values are in the range of 1e6 S/m, we need the new units kS and MS
- since this is for simulations, also add electrical conductivity to the FEM material cards
2021-03-25 17:13:52 +01:00
luz paz
bfdffb50be
App: Fix header uniformity, trailing whitespace, and doxygen headers
2020-11-19 13:38:37 +01:00
Zheng, Lei
3beb1bff21
App: improve FunctionExpression forward compatibility
...
Remove runtime check when constructing FunctionExpression, in order to
support future built-in function. Exception will be thrown when
evaluating the expression to inform user about the error.
2020-06-03 22:18:39 +02:00
donovaly
66354b3c58
add units Gauss, Weber and Oersted
2020-01-07 07:36:22 -03:00
donovaly
ca07b05fab
ExpressionParser.l: fix a typo
2020-01-05 15:00:46 +01:00
donovaly
05dadb4c75
add the units Ohm and Siemens
2020-01-05 15:00:46 +01:00
luz.paz
4f308dc03c
src/App: [skip ci] fix header uniformity
...
This PR fixes header uniformity across all `src/App` files
2019-12-25 11:38:43 +01:00
donovaly
6aeb0910b8
cosmetics to keep the overview
2019-12-24 13:31:00 +01:00
donovaly
cd8b63028c
missing parts from from commit d9d903faea
...
- also add keV and MeV since these are the units used in practice
2019-12-24 13:31:00 +01:00
donovaly
9c707479a6
also add unit THz as requested
2019-12-23 16:49:45 +01:00
donovaly
63bc9c5683
add units Mpsi, cal and kcal
...
- also ass missing parts from commit d7ca604c
2019-12-23 16:49:45 +01:00
donovaly
2949afb55b
add mJ and kW
...
- also some fixes
- add conversions for forces
2019-12-19 13:31:12 +01:00
donovaly
82dc8e88f5
add the following units:
...
- mmol
- ml
- bar
- mbar
- kJ
- kWh
- eV
- C
- T
- F (p, n, u, m)
- H (n, u, m)
2019-12-19 13:31:12 +01:00
Zheng, Lei
a1417c5ffa
App: extend Expression syntax
...
* Support sub-object reference syntax using the following syntax,
Part.<<Box.>>.Placement
or, with sub-object label referencing
Part.<<$Cube.>>.Placement
* Extend indexing support, including range based indexing, e.g.
A1[B2+1][C3][D4:-1]
* Add new constants, None, True, true, False, false.
2019-09-28 15:31:24 +02:00
Zheng, Lei
d141975701
App: use Python number protocol in Expression
...
This adds support to do mul/div with matrix and vector, as well as
Python formated string with operator %.
2019-09-28 15:30:34 +02:00
Zheng, Lei
278e933527
App: allow starting '_' in an expression identifier
...
It's a signle line change in the flex source, bug a big change in the
generated source.
2019-08-30 14:47:53 +02:00
wandererfan
1b854e029b
Add support for DMS angles to Expressions
2018-12-23 11:03:02 -02:00
wmayer
1673ab801e
use specialized exception classes
2017-04-28 18:49:11 +02:00
Eivind Kvedalen
08692f811b
Expressions: Added support for aggregate functions and ranges.
2016-04-02 12:01:04 +02:00
Eivind Kvedalen
8ce2f16759
Expressions: Added code to throw under/overflow exceptions.
2016-03-08 16:09:29 +01:00
Eivind Kvedalen
7b39e233e3
Expression parser: Fixed parsing of numbers like 2e3 (with e/E, but without decimal part).
2015-09-23 20:05:01 +02:00
Eivind Kvedalen
722a40dd41
Added Expression classes to App directory. Added Expression interface to Property base class.
2015-09-21 14:51:02 +02:00