Plotting strings

Plotting strings - Messages

#1 Posted: 5/25/2021 8:10:14 PM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Hi!

When I want to plot text/strings, I add mat(1;5) to my graph. Strings usually has top left justification.

Is it possible to set justification as the sixth element of the matrix?

Best regards.
#2 Posted: 5/26/2021 3:22:32 AM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote

Wrote

Is it possible to set justification as the sixth element of the matrix ?


No need AFAIK.



Hello Jean,

Take a look at the attached image. I want C to have top right justification, and B bottom right. I could just offset the coordinates for a quick fix, but when I change the zoom level that will not work.

Best regards,

trig.PNG
#3 Posted: 5/26/2021 9:11:04 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

Hello Jean,
Take a look at the attached image. I want C to have top right justification, and B bottom right. I could just offset the coordinates for a quick fix, but when I change the zoom level that will not work.
Best regards,


For fixed rotation, you can get inspired from the attached.
Smath is not a CAD, but from little it does so much.
This W Truss originates from Ioan [SS 5346 ?]
End result from multiple collaboration [Alyles, Carlos, Jean].
Next from you: *.sm document.
Cheers ... Jean

Utilities XY [Draw Truss Labels ZOOMED mode].sm (26 KiB) downloaded 93 time(s).

#4 Posted: 5/26/2021 10:39:47 AM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote


For fixed rotation, you can get inspired from the attached.
Smath is not a CAD, but from little it does so much.
This W Truss originates from Ioan [SS 5346 ?]
End result from multiple collaboration [Alyles, Carlos, Jean].
Next from you: *.sm document.
Cheers ... Jean



Jean,

Your example seems to work well when zooming out. When zooming in the labels starts getting further appart fram the drawing.

I was hoping maybe this was something the developers could incorporate in an upcoming release.

Best regards,
#5 Posted: 5/26/2021 2:24:37 PM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote


You are asking a CAD functionality that does not have much interest.
This triangle has some curious relationship.
Most probably each figure will have more surprises + rotation.
What is the interest of zooming a triangle ?
That one, you can zoom/rotate at will for [Area/Perimeter/CG]
[Area/Perimeter/CG] for any figure of XY vertices.
Where are you in your design ? ... Jean.



Jean,

I was just puzzling around with trigonometry. I never seem to remember the trigonometric relationships, so rather than googling 'trigonometric functions' all the time, I figured it would be fun to try to make something in SMath.

Attached is the "project" I was fooling around with. I tried to plot an angle (L) in all the corners that were 90°, but because of the significant round-off errors I skipped that part.

Best regards,

Trigonometry.sm (39 KiB) downloaded 81 time(s).
#6 Posted: 5/26/2021 3:42:27 PM
overlord

overlord

554 likes in 1333 posts.

Group: Moderator

Wrote

Attached is the "project" I was fooling around with. I tried to plot an angle (L) in all the corners that were 90°, but because of the significant round-off errors I skipped that part.


This is a very good example.
Nice job, kudos to your project.

Regards
#7 Posted: 5/26/2021 4:16:54 PM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote


This is a very good example.
Nice job, kudos to your project.

Regards



Thank you, far too kind!

Best regards,
#8 Posted: 5/26/2021 6:54:42 PM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote

Your zoomed triangle is pure success from brute force refactoring.
Sorry for the 5 hours power failure from unusual strong wind.
Thanks for this nice project ... Jean

Trigonometry.sm (49 KiB) downloaded 67 time(s).



I guess zooming in and out on the plot could be avoided by resizing the triangle within the plot.. and that way shifting/aligning the labels manually will work just fine.

Best regards,
#9 Posted: 5/27/2021 8:04:45 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Last brick in the wall for that one.
Medians [med] approximate, not from calculations.
More maths added for convenience.
Thanks for that superb Classroom ... Jean

Utilities XY [Draw ZOOM Triangle].sm (20 KiB) downloaded 70 time(s).
#10 Posted: 5/28/2021 7:10:15 AM
hanskl

hanskl

7 likes in 158 posts.

Group: User

Wrote

Last brick in the wall for that one.
Medians [med] approximate, not from calculations.
More maths added for convenience.
Thanks for that superb Classroom ... Jean



Jean,

Very interesting! Thanks for the insight.

Best regards,
#11 Posted: 5/28/2021 10:57:10 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

Very interesting! Thanks for the insight.


... added rotation of a new triangle.
Take care ... Jean

Utilities XY [Draw ZOOM Triangle] Copy.sm (47 KiB) downloaded 59 time(s).
  • New Posts New Posts
  • No New Posts No New Posts