Effacer les filtres
Effacer les filtres

geometrical figure as string

3 vues (au cours des 30 derniers jours)
v k
v k le 6 Nov 2020
Commenté : v k le 6 Nov 2020
Hello,
The following code generates a dashed circle, with a solid semi-circle on top of it.
clear all
r1=1;
theta1=linspace(0,2*pi,100);
ox1=0;oy1=0;
x1=ox1+r1*cos(theta1);
y1=oy1+r1*sin(theta1);
r2=0.5;
theta2=linspace(pi/2,3*pi/2,50);
ox2=0;oy2=r1+r2;
x2=ox2+r2*cos(theta2);
y2=oy2+r2*sin(theta2);
figure;
hold on
plot(x1,y1,'--')
plot(x2,y2,'-')
grid('off')
axis('equal')
axis('off')
Is it possible to use this code somehow, and to use the figure obtained by it as a string entity? That is, if the generated figure is 'f', then
str{1}='f'
should give the above figure.
Thanks. It cannot be a figure though ...
  2 commentaires
KSSV
KSSV le 6 Nov 2020
If you take
h = figure ;
You have the figure handles in h now.
v k
v k le 6 Nov 2020
Hello KSSV, I guess I don't understand how this figure handle can give string representation of the figure.
To be precise, I am trying to obtain the burmese character given by the unicode number U+103A. But it does not print out, and only gives a box in the figure and the command window, even after using UTF8 as the character set. This unicode number is the exact figure of dotted circle with a solid semi-circle on top of the dotted circle.
How can I save this character as a string? Thanks. And sorry if my question was vague before.

Connectez-vous pour commenter.

Réponses (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by