<commit_before>module Drasil.DblPendulum.Expressions where

import Prelude hiding (sin, cos, sqrt)
import Language.Drasil

import Data.Drasil.Quantities.Physics(velocity,
    angularAccel, xAccel, yAccel, acceleration, gravitationalAccel,
    angularFrequency, torque, momentOfInertia, time,
    momentOfInertia, period)
import Data.Drasil.Quantities.PhysicalProperties (mass)
import qualified Data.Drasil.Quantities.Math as QM (pi_)
import Drasil.DblPendulum.DataDefs (positionXDD_1, positionYDD_1, positionXDD_2, positionYDD_2, 
    positionGDD, accelGDD)
import Drasil.DblPendulum.Unitals (lenRod_1, lenRod_2, angularVel_1, angularVel_2,
    pendDisAngle_2, xVel_1, xVel_2, yVel_1, yVel_2, xPos_1, xPos_2, yPos_1,
    yPos_2, xAccel_1, yAccel_1, xAccel_2, yAccel_2, pendDisAngle_1, angularAccel_1,
    angularAccel_2, tension_1, tension_2, massObj_1, massObj_2)
import Control.Lens ((^.))

-- Velocity X/Y First Object
velXExpr_1, velYExpr_1 :: Expr
velXExpr_1 = sy angularVel_1 `mulRe` sy lenRod_1 `mulRe` cos (sy pendDisAngle_1)
velYExpr_1 = sy angularVel_1 `mulRe` (positionXDD_1 ^. defnExpr)

velDerivEqn1, velXDerivEqn2_1, velXDerivEqn3_1, velXDerivEqn4_1 :: Expr
velDerivEqn1 = sy velocity $= positionGDD ^. defnExpr
velXDerivEqn2_1 = sy xPos_1 $= positionXDD_1 ^. defnExpr
velXDerivEqn3_1 = sy xVel_1 $= deriv (positionXDD_1 ^. defnExpr) time
velXDerivEqn4_1 = sy xVel_1 $= sy lenRod_1 `mulRe` deriv (sin (sy pendDisAngle_1)) time<commit_msg>remove redundant import in expression<commit_after>module Drasil.DblPendulum.Expressions where

import Prelude hiding (sin, cos, sqrt)
import Language.Drasil

import Data.Drasil.Quantities.Physics(velocity, acceleration, gravitationalAccel, time)
import Drasil.DblPendulum.DataDefs (positionXDD_1, positionYDD_1, positionXDD_2, positionYDD_2, 
    positionGDD, accelGDD)
import Drasil.DblPendulum.Unitals (lenRod_1, lenRod_2, angularVel_1, angularVel_2,
    pendDisAngle_2, xVel_1, xVel_2, yVel_1, yVel_2, xPos_1, xPos_2, yPos_1,
    yPos_2, xAccel_1, yAccel_1, xAccel_2, yAccel_2, pendDisAngle_1, angularAccel_1,
    angularAccel_2, tension_1, tension_2, massObj_1, massObj_2)
import Control.Lens ((^.))

-- Velocity X/Y First Object
velXExpr_1, velYExpr_1 :: Expr
velXExpr_1 = sy angularVel_1 `mulRe` sy lenRod_1 `mulRe` cos (sy pendDisAngle_1)
velYExpr_1 = sy angularVel_1 `mulRe` (positionXDD_1 ^. defnExpr)

velDerivEqn1, velXDerivEqn2_1, velXDerivEqn3_1, velXDerivEqn4_1 :: Expr
velDerivEqn1 = sy velocity $= positionGDD ^. defnExpr
velXDerivEqn2_1 = sy xPos_1 $= positionXDD_1 ^. defnExpr
velXDerivEqn3_1 = sy xVel_1 $= deriv (positionXDD_1 ^. defnExpr) time
velXDerivEqn4_1 = sy xVel_1 $= sy lenRod_1 `mulRe` deriv (sin (sy pendDisAngle_1)) time
{'fraction_non_alphanumeric': 0.08946395563770795, 'fraction_numerical': 0.04288354898336414, 'mean_word_length': 6.313513513513514, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3634254', 'n_tokens_mistral': 1154, 'n_tokens_neox': 1118, 'n_words': 236}