I have been trying to model crater formation on a given planetary surface - $500\,\textrm{km}^2$. The locations of impacts are random, however, if an impact is within $30\,\textrm{km}$ of another, the previous crater is considered eliminated.
So far I have used RandomReal[0,500]
for both the $x$ any $y$ coordinate values on the $500\,\textrm{km}^2$ plot. My problem is that the arrangement of craters changes for every evaluation I do. What I'm looking to achieve is a cumulation of craters, one by one."Drawn on" so to speak. This way, appropriate crater destruction can also ensue.
I am also still trying to figure out a way to model crater destruction. As I mentioned, if an impact location is within $30\,\textrm{km}$ of another, the previous crater is eliminated. I tried using If[EuclideanDistance[],...]
but no luck.
The code I used for crater location (points) is:
craterlocations = Table[{RandomReal[{0, 500}], RandomReal[{0, 500}]}, {n}]
p1 = ListPlot[craterlocations]
I need to produce a similar plot, but the craters should continually form. As of now I will always wind up with a different random arrangement for each number of impacts (n
).
Read the FAQs
! 3) When you see good Q&A, vote them up byclicking the gray triangles
, because the credibility of the system is based on the reputation gained by users sharing their knowledge. ALSO, remember to accept the answer, if any, that solves your problem,by clicking the checkmark sign
$\endgroup$