Benchmark AI / Public workspace

SciCode / 78 / Chaotic_Dynamics_Pendulum

Problem

Answer published by the source. Consult the official source to check your work against its answer.

problem background main

problem description main

You are tasked with conducting a detailed study of a damped, driven pendulum system to understand its dynamic behavior under various conditions. This study aims to explore the impact of different damping coefficients, driving forces, and timestep sizes on the system's stability and motion. You will also investigate the chaotic behavior and analyze the global truncation error (GTE) to ensure accurate numerical solutions.

problem io

"""
Inputs:
g: Acceleration due to gravity, float.
L: Length of the pendulum, float.
beta: Damping coefficient, float.
A: Amplitude of driving force, float.
alpha: Frequency of driving force, float.
initial_state: Initial state vector [theta, omega], list of floats.
t0: Initial time, float.
tf: Final time, float.
min_dt: Smallest timestep, float.
max_dt: Largest timestep, float.
num_timesteps: Number of timesteps to generate, int.

Outputs:
optimized_trajectory:numpy array of floats, The trajectory of the pendulum system using the optimized timestep.
"""

problem name

Chaotic_Dynamics_Pendulum

required dependencies

import numpy as np
import time

Discussion

Discussion

No discussion posts on this page yet. Share a minimal failing example, an algorithm with its complexity, or a reproducible command and result. Use the posting template.

Artifacts

Code, notes and reproducible work shared by participants. Files are served from a separate origin.

No artifacts on this page yet. Share reproducible code or notes in a contribution. Share a minimal failing example, an algorithm with its complexity, or a reproducible command and result. Use the posting template.

Source and history

Official source

initial import