[SS-2368] Unit behavior - units don't match issue

[SS-2368] Unit behavior - units don't match issue - Reciprocal units don't match when reciprocated - Poruke

#1 Objavljeno: 5. 8. 2016. 20:19:36
fred47

fred47

0 svidjanja u 1 postova.

Grupa: User

Hi,

I have run into a problem with using units which are reciprocals - specifically Ohms and Siemens.

If I try to add a quantity with units Ohms to the reciprocal of a quantity with units Siemens, an error occurs: Units don't match.

Due to computer limitations where I am presently, I have only text entry.

Example:

Ra := 1 Ohm
Ga := 1 S
Rsum := Ra + 1/Ga = "units don't match"

But they do cancel:

Rprod := Ra * Ga = 1

Is there a work-around I'm missing somehow?

Thanks,
Fred
#2 Objavljeno: 6. 8. 2016. 10:20:10
Davide Carpi

Davide Carpi

1.444 svidjanja u 2.936 postova.

Grupa: Moderator

Hello Fred,

it is a bug; as workaround you can transit through a 3rd variable with symbolic optimization on his definition, then it is possible to evaluate numerically this variable in a separate region (see the cloud example)

2016-08-06 15_21_29-SMath Studio Desktop - [OhmSiemens.sm_].png
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#3 Objavljeno: 18. 8. 2016. 05:45:41
nierges

nierges

0 svidjanja u 3 postova.

Grupa: User

Hi,

I was trying to implement a formula to calculate needed inductance on a flyback transformer and the program reports that units do not match. However splitting the formula in smaller pieces I was able to get the result out of it.
units dont match.sm (34,23 KiB) preuzeto 1419 put(ova).

Thank you.
#4 Objavljeno: 18. 8. 2016. 05:53:04
Davide Carpi

Davide Carpi

1.444 svidjanja u 2.936 postova.

Grupa: Moderator

It is the same bug as the one shown in the first post, so I moved your post here.

The problem is related to the numeric evaluation, but there is a workaround:
- remove the RHS (the evaluation = and all after it)
- change optimization to symbolical
- show the result alone (Lp=#)


Bug reported as SS-2368
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 korisnika je svidelo ovu objavu
nierges 19. 8. 2016. 05:10:00
#5 Objavljeno: 19. 8. 2016. 05:11:59
nierges

nierges

0 svidjanja u 3 postova.

Grupa: User

Wrote

It is the same bug as the one shown in the first post, so I moved your post here.

The problem is related to the numeric evaluation, but there is a workaround:
- remove the RHS (the evaluation = and all after it)
- change optimization to symbolical
- show the result alone (Lp=#)


Bug reported as SS-2368



Thank you Davide, seems to work following your advice.
Emil
#6 Objavljeno: 19. 8. 2016. 12:07:49
Andrey Ivashov

Andrey Ivashov

2.345 svidjanja u 4.060 postova.

Grupa: Super Administrator

Both issues fixed. See latest available nightly build: http://en.smath.info/forum/yaf_postst7698_SMath-Studio-0-98-6073--19-August-2016.aspx
1 korisnika je svidelo ovu objavu
Davide Carpi 19. 8. 2016. 20:35:00
  • Novi postovi
  • Nema novih postova