Extend point definition with an checkbox

Rumburak shared this question 5 years ago
Answered

An point A move on two segments.


Point definition : Point[{f, g}]


When I click an checkbox I want to extend point definition with more one line :


New Point definition : Point[{f, g,h}]


how can I do?

Comments (10)

photo
1

If the name of your checkbox is "c", use

  1. A=If[c , Point[{f, g,h}], Point[{f, g] ]

photo
2

If you want it to be moveable you should use use

R2=Point[If[c , {f, g,h}, {f, g} ]]

photo
1

Yes, I thought that it is easier to add. The problem is that in reality there are many points and segments and the textbox "Definition" is too small ...

Thanks for help

photo
2

If you have 100 segments and the segments are the content of spreadsheet column "A",

you will get the set of these 100 segments with the simple and short input

  1. A1:A100

photo
1

Yes, work fine.


Can you tell me how to do a cells union ?

ex: A1:A3 and A5:A10

photo
1

Point[If[¬(o ∨ p ∨ q), {B1:B3}]] work fine

But I need

{B1:B3} AND {A1:A12}

photo
photo
2

Join[{B1:B3, A1:A12}]

photo
1

Yes. Is perfect !


Thank you very much !

photo
photo
1

Point A move on segments depending chexbox df1,dc1,nf1 :

Point[If[(df1 ∨ dc1 ∨ nf1) ≟ false, Join[{B1:B12}], df1, Join[{B1:B12, A1:A12}], dc1, Join[{B1:B12, A16:A19}], nf1, Join[{B1:B12, A13:A15}]]]

Point B :

Point[If[(df2 ∨ dc2 ∨ nf2) ≟ false, Join[{B1:B12}], df2, Join[{B1:B12, A1:A12}], dc2, Join[{B1:B12, A16:A19}], nf2, Join[{B1:B12, A13:A15}]]]

Point C :

Point[{a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, A1:A20}]

First time everything is ok.

After a while points A and B moves only in one segment but point C is ok.

After close and open Geogebra all is ok. For now.

That is a big problem.


Addendum :

In each checbox (set of three chexbox) because I want only one to be active I have :

On Update script :

dc1=false

nf1=false

photo
1

Sorry, it is my mistake.


I replaced dc1=false with SetValue[dc1,false] and work fine allways.

© 2021 International GeoGebra Institute