Properties
Similar Topics
Statistics
Comments
2
Participants
2
Subscribers
2
Votes
1
Views
557
Share
Creating polygons using sequence
Answered
I made some polygons using the sequence function
Sequence(Polygon((2k, 0), (2k + 1, 0), (2k + 1, 10), (2k, 10)), k, 0, Tens  1)
while Tens is a integer slider.
When Tens=1, only one polygon will show (i.e. the leftmost one).
The picture below shows Tens=6
Actually I would like to divide each polygon into 10 smaller pieces (just to add lines like the leftmost polygon)
I used sequence command to create those lines.
Sequence(Segment((0, k), 1), k, 1, 9)
but this command only apply to the leftmost polygon.
Therefore, I would like to ask how should I do in order to create the segments for the other polygons?
 GeoGebra
 Help
 Partners

Contact us
 Feedback & Questions
 This email address is being protected from spambots. You need JavaScript enabled to view it.
 +43 677 6137 2693
© 2021 International GeoGebra Institute
Sequences can be nested.
Take your first sequence without the expression for the polygon.
and replace the polygonexpression with your second sequence.
But this so that there are different indexes for both sequences (i and k).
Use these two indexes for the segment command.
.
Note: The above syntax for the segment does not work in GGB5.0
The following syntax would probably be better

Alternative:
Create squares instead of segments in the nested sequence (and delete your first sequence).

Note:
It is easier for me (and also for you) if you only use the object names instead of the written commands and attach the current status of your application as a GGB file.
with squares, expanded
Comments have been locked on this page!