Problem with simple 2D plot

Problem with simple 2D plot - Messages

#1 Posted: 7/19/2021 12:41:14 PM
trawqa18

trawqa18

0 likes in 6 posts.

Group: User

Hi everyone. In work I used MathCad, but when I heared about Smath Studio - I wanna try it at home. But..... I have problem. I want to rewrite one calculation sheet from MathCad to Smath.

Here is fragment from MathCad: 1.PNG


I try to rewrite the same calculation to Smath but I can't correctly generate plot: 2.PNG

What I do wrong? I can't find error. BTW: I can't apply "x" range like I made it in MathCad.Can someone help me? Maybe make simple working file with solution on my problem? I already don't have any idea... I try for few days after works.
#2 Posted: 7/19/2021 1:46:10 PM
overlord

overlord

552 likes in 1332 posts.

Group: Moderator

Wrote

What I do wrong? I can't find error. BTW: I can't apply "x" range like I made it in MathCad.Can someone help me? Maybe make simple working file with solution on my problem? I already don't have any idea... I try for few days after works.


Here is your worksheet.
Smath don't have mathcad x define while plotting.
We generally augment x with results.
While unit version shall plot too, better to make eliminating a habbit.
PS: updated post with cases(), a simpler and easier if() replacement.

Regards

mg(x).sm (15 KiB) downloaded 24 time(s).

2021-07-20_01-48.png
#3 Posted: 7/19/2021 2:32:10 PM
trawqa18

trawqa18

0 likes in 6 posts.

Group: User

Thanks MAN! Now I have starting point


How you define Mg? This arrow came from?
3.PNG
#4 Posted: 7/19/2021 3:21:33 PM
overlord

overlord

552 likes in 1332 posts.

Group: Moderator

Wrote

Thanks MAN! Now I have starting point


How you define Mg? This arrow came from?


That is vectorize() function.
You can either type it as a function or select from toolbar.

Regards
#5 Posted: 7/20/2021 8:22:45 AM
Oscar Campo

Oscar Campo

124 likes in 298 posts.

Group: Moderator

Wrote

Hi everyone. In work I used MathCad, but when I heared about Smath Studio - I wanna try it at home. But..... I have problem. I want to rewrite one calculation sheet from MathCad to Smath.
...



Hi!
Here is a little different way to express your model and find your answer, maybe it could be interesting:


BySingularityFunctions.png



You can download the Smath file here: BySingularityFunctions.sm (25 KiB) downloaded 30 time(s).

Regards.
#6 Posted: 7/20/2021 11:21:04 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

mg(x) More for Convenience.sm (17 KiB) downloaded 37 time(s).
#7 Posted: 7/27/2021 1:12:17 PM
trawqa18

trawqa18

0 likes in 6 posts.

Group: User

I try to make Mg(x) fragment on my own... How you done this? 222222.PNG

I wanna to have mm on plot "x". How can I change that?


I'm trying to make this file in Smath (Yi n'Yama n'syuc - Rolka jezdna.pdf (211 KiB) downloaded 33 time(s).
#8 Posted: 7/27/2021 2:16:12 PM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

I try to make Mg(x) fragment on my own... How you done this?


Fragment as suggested 3 different ways.
No system will respond to invented code.

#9 Posted: 7/27/2021 2:28:49 PM
trawqa18

trawqa18

0 likes in 6 posts.

Group: User

I'm try to understeund how somebody write it... I can't reproduce that record.

I mean, I don't know in what order I must click specific function to get this "function"
#10 Posted: 7/27/2021 2:50:21 PM
Davide Carpi

Davide Carpi

1416 likes in 2873 posts.

Group: Moderator

The symbolic stuff is, from outer to inner:
line(
vectorize(
cases(

cases is from "custom functions" plugin, therefore to have it in your functions you have to install the extension first.

line and vectorize are available also in the toolboxes on RHS of the worksheet area.

About unit scaling, divide by 'mm instead of 'm (a mm is 1/1000 m, so the output will be magnified by a 10E3 factor)
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#11 Posted: 7/27/2021 3:25:18 PM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

I'm try to understand how somebody write it... I can't reproduce that record.
I mean, I don't know in what order I must click specific function to get this "function"


Here is the 4th code ... set 'n' as you wish to fragment.

Fragment.PNG
#12 Posted: 7/27/2021 3:30:42 PM
trawqa18

trawqa18

0 likes in 6 posts.

Group: User

Davide, that is what I'm talking about. Thanks man!
  • New Posts New Posts
  • No New Posts No New Posts