Skip to content
Permalink
8a917ec4de
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
6 lines (6 sloc) 316 Bytes
function [ PE ] = collar_potential_energy( x ) %designated PE function for collar
theta = 0.9; %theta value
PE_g = (0.5)*x*(-9.8)*sin(theta); %potential energy due to gravity
PE_s = (0.5)*30*((0.5)-sqrt((0.5)^2+((0.5)-x)^2))^2; %potential energy due to spring
PE = PE_g + PE_s; %total potential
end