coding UTF-8; // Load libraries import tool.Graph2D; // Required for handling 2D graphs import Math; // Required for mathematical functions // Prepare arrays for plotting int pointN = 30; // Number of points float xData[pointN]; // Array to store X coordinates float yData[pointN]; // Array to store Y coordinates // Set plot range float xMax = 10.0; // Maximum X value float xMin = 0.0; // Minimum X value float yMax = 1.0; // Maximum Y value float yMin = -1.0; // Minimum Y value // Launch the 2D graph and configure settings int graph = newGraph2D(); // Launch graph setGraph2DRangeX(graph, xMin, xMax); // Set X range setGraph2DRangeY(graph, yMin, yMax); // Set Y range setGraph2DAutoRange(graph, false, false); // Disable auto-scaling //setGraph2DOption(graph, "WITH_POINTS", false); // Uncomment to disable point markers (lines only) // Animation loop (counts frames using the variable 'frame') for (int frame=0; true; frame++) { // Set a frame limit if needed, e.g., frame<=1000 // Calculate time t based on the current frame float t = 0.05 * frame; // Larger coefficient = faster animation // Update coordinate arrays for(int i=0; i