MGBureauDrawersPushOnInclinedPlaneStaticFriction.html  (MotionGenesis input/output).
   (1) %     File: MGBureauDrawersPushOnInclinedPlaneStaticFriction.txt 
   (2) %  Problem: Determine forces to keep bureau in static equilibrium.
   (3) %--------------------------------------------------------------------
   (4) NewtonianFrame  N            % Earth.
   (5) RigidBody       B            % Bureau (chest of drawers).
   (6) Point           P(B)         % Point where person pushes bureau.
   (7) Point           O(B), Q(B)   % Points where B contacts inclined plane.
   (8) %--------------------------------------------------------------------
   (9) Constant  g = 10 m/s^2       % Earth's gravitational acceleration.
   (10) Constant  h = 0.5 m          % Distance between O and P.
   (11) Constant  L = 0.2 m          % Half-distance between O and Q.
   (12) Constant  d = 0.3 m          % Distance between Bcm and line OQ.
   (13) Constant  theta = 30 degs    % Angle between Nx> and Bx> (hill angle).
   (14) Variable  Fp                 % Bx> measure of human force on P.
   (15) Variable  FOx, FOy           % -Bx> and By> measures of contact force on point O.
   (16) Variable  FQx, FQy           % -Bx> and By> measures of contact force on point Q.
   (17) B.SetMass( m = 10 kg )        
   (18) %--------------------------------------------------------------------
   (19) %       Geometry
   (20) B.SetRotationMatrixZ( N, theta )
-> (21) B_N = [cos(theta), sin(theta), 0;  -sin(theta), cos(theta), 0;  0, 0, 1]

   (22) P.SetPosition( O, h*By> )
-> (23) p_O_P> = h*By>

   (24) Q.SetPosition( O, 2*L*Bx> )
-> (25) p_O_Q> = 2*L*Bx>

   (26) Bcm.SetPosition( O, L*Bx> + d*By> )
-> (27) p_O_Bcm> = L*Bx> + d*By>

   (28) %--------------------------------------------------------------------
   (29) %       Contact and distance forces.
   (30) P.AddForce( FP*Bx> )
-> (31) Force_P> = Fp*Bx>

   (32) O.AddForce( -FOx*Bx> + FOy*By> )
-> (33) Force_O> = -FOx*Bx> + FOy*By>

   (34) Q.AddForce( -FQx*Bx> + FQy*By> )
-> (35) Force_Q> = -FQx*Bx> + FQy*By>

   (36) Bcm.AddForce( -m*g*Ny> )
-> (37) Force_Bcm> = -m*g*Ny>

   (38) %--------------------------------------------------------------------
   (39) %       Static equilibrium of B.
   (40) StaticEqn[1] = Dot( B.GetResultantForce(),  Bx> )
-> (41) StaticEqn[1] = Fp - m*g*sin(theta) - FOx - FQx

   (42) StaticEqn[2] = Dot( B.GetResultantForce(),  By> )
-> (43) StaticEqn[2] = FOy + FQy - m*g*cos(theta)

   (44) StaticEqn[3] = Dot( B.GetMomentOfForces(O), Bz> )
-> (45) StaticEqn[3] = m*g*(d*sin(theta)-L*cos(theta)) + 2*L*FQy - h*Fp

   (46) %--------------------------------------------------------------------
   (47) %       Symbolic solution for clockwise tipping (losing contact at point O).
   (48) ClockwiseTipping = Evaluate( StaticEqn,  FOx = 0, FOy = 0 )
-> (49) ClockwiseTipping[1] = Fp - m*g*sin(theta) - FQx
-> (50) ClockwiseTipping[2] = FQy - m*g*cos(theta)
-> (51) ClockwiseTipping[3] = m*g*(d*sin(theta)-L*cos(theta)) + 2*L*FQy - h*Fp

   (52) Solve( ClockwiseTipping = 0,  Fp, FQx, FQy )
-> (53) Fp = m*g*(d*sin(theta)+L*cos(theta))/h
-> (54) FQx = -m*g*(sin(theta)-(d*sin(theta)+L*cos(theta))/h)
-> (55) FQy = m*g*cos(theta)

   (56) %--------------------------------------------------------------------
   (57) %       Solve for h required for tipping in terms of d, L, theta, and mus.
   (58) %       Multiply both sides of equation by h to make it linear in h.
   (59) Constant  mus                % Coefficient of static friction.
   (60) StaticFrictionEqn = h * ( Rhs(FQx) - mus*Rhs(FQy) )
-> (61) StaticFrictionEqn = m*g*(d*sin(theta)+L*cos(theta)-h*(sin(theta)+mus*
        cos(theta)))

   (62) hTip = Solve( StaticFrictionEqn = 0,  h )
-> (63) hTip = [(d*sin(theta)+L*cos(theta))/(sin(theta)+mus*cos(theta))]

   (64) %--------------------------------------------------------------------
   (65) %       Matrix form (A*X = B) of equations when sticking.
   (66) CoefficientMatrix = GetCoefficientMatrix( StaticEqn, Fp, FOy, FQy, FOx, FQx  )
-> (67) CoefficientMatrix = [1, 0, 0, -1, -1;  0, 1, 1, 0, 0;  -h, 0, 2*L, 0, 0]

   (68) RemainderMatrix   = Exclude( -StaticEqn, Fp, FOy, FQy, FOx, FQx  )
-> (69) RemainderMatrix = [m*g*sin(theta);  m*g*cos(theta);  -m*g*(d*sin(theta)-L*cos(theta))]

   (70) %--------------------------------------------------------------------
Saved by Motion Genesis LLC.   Command names and syntax: Copyright (c) 2009-2019 Motion Genesis LLC. All rights reserved.