Showing trace when condition meets

FangShin shared this question 3 months ago
Answered

Hi.

I want to draw a trace of a moving point which has same length from two fixed points.

I have tried to write script OnUpdate as " If(a==b,SetTrace(P,true),SetTrace(P,False)) ". But nothing show out. So what can I do now ?

Thanks in advanced.

Best Answer
photo

I use an auxiliary point for this, with trace on always, but only shown when the condition meets. So I have to write a condition to show a point and not to show a trace. Doing so, I even give the trace another color then the original point. In the file added you can drag a point P and a point PP=P with trace on is only shown when absolute value of the difference between the distance to points A and B is less than 0.1 (to build in a slight margin). Of course you can play with this margin and/or the pointstyle of PP

3bbbb26acd4db1fce37a559930103089


chris

Comments (6)

photo
2

Hi

please upload your ggb file.

photo
1

Hi. I had solved my problem. Thanks for your help :)

photo
photo
2

which has same length from two fixed points


a point in perpendicular bisector????

photo
1

yes. it is the perpendicular bisector. What I want is the trace of the moving point without showing perpendicular bisector.

photo
photo
3

I use an auxiliary point for this, with trace on always, but only shown when the condition meets. So I have to write a condition to show a point and not to show a trace. Doing so, I even give the trace another color then the original point. In the file added you can drag a point P and a point PP=P with trace on is only shown when absolute value of the difference between the distance to points A and B is less than 0.1 (to build in a slight margin). Of course you can play with this margin and/or the pointstyle of PP

3bbbb26acd4db1fce37a559930103089


chris

photo
1

I followed your ways and it works !!! And I also learned Boolean Value test as well ( which I never used it before)

Really appreciate it. Thanks a lot !!!

photo
© 2020 International GeoGebra Institute