diff --git a/notebooks/Material_Parameters.ipynb b/notebooks/Material_Parameters.ipynb
new file mode 100644
index 0000000..2d66b12
--- /dev/null
+++ b/notebooks/Material_Parameters.ipynb
@@ -0,0 +1,1466 @@
+{
+ "cells": [
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "metadata": {},
+ "outputs": [
+ {
+ "name": "stderr",
+ "output_type": "stream",
+ "text": [
+ "┌ Info: Precompiling Plots [91a5bcdd-55d7-5caf-9e0b-520d859cae80]\n",
+ "└ @ Base loading.jl:1273\n"
+ ]
+ }
+ ],
+ "source": [
+ "using Unitful:mm,\n",
+ " m,inch,Pa,K,Hz,kHz,GPa, Pressure, Temperature, Frequency,ustrip, MPa\n",
+ "using Plots"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "stress (generic function with 1 method)"
+ ]
+ },
+ "execution_count": 6,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "# Parameters to the Johnson Cook flow stress model\n",
+ "abstract type PlasticModel end\n",
+ "struct MaterialModel\n",
+ " E_y::Pressure \n",
+ " σ_y::Pressure\n",
+ " plastic::PlasticModel\n",
+ "end\n",
+ "struct JohnsonCookParams <: PlasticModel\n",
+ " ∂ϵ_∂t_0::Frequency\n",
+ " T_room::Temperature\n",
+ " T_m::Temperature\n",
+ " T_test::Temperature\n",
+ " A::Pressure\n",
+ " B::Pressure\n",
+ " C\n",
+ " n\n",
+ " m\n",
+ "end\n",
+ "struct KNParams <: PlasticModel\n",
+ " K::Pressure\n",
+ " N::Real\n",
+ "end\n",
+ "\n",
+ "#Parameters to the Cowper Symonds yeild stress model\n",
+ "struct CowperSymondsParams <: PlasticModel\n",
+ " A::Pressure\n",
+ " B::Pressure\n",
+ " C::Frequency\n",
+ " p\n",
+ " P\n",
+ "end\n",
+ "\n",
+ "#Parameter to the Ludwik yeild stress model\n",
+ "struct LudwikParams <: PlasticModel\n",
+ " A::Pressure\n",
+ " B::Pressure\n",
+ " C\n",
+ "end\n",
+ "units = Pa\n",
+ "\n",
+ "function yieldStress(plasticModel::PlasticModel, materialModel::MaterialModel, ∂ϵ_∂t::Frequency)::Pressure\n",
+ " materialModel.σ_y \n",
+ " end\n",
+ "function yieldStress(csp::CowperSymondsParams, materialModel::MaterialModel, ∂ϵ_∂t::Frequency)::Pressure\n",
+ " materialModel.σ_y*(1+(∂ϵ_∂t/csp.C)^(1/csp.P))\n",
+ "end\n",
+ "\n",
+ "#Function that calculates the stress of the material after the yeild point\n",
+ "#CowperSymonds\n",
+ "function plasticStress(σ_y::Pressure, ϵ_plastic::Real, ∂ϵ_∂t::Frequency, materialModel::MaterialModel, csp::CowperSymondsParams):: Pressure\n",
+ " σ_y+csp.B*ϵ_plastic^csp.p*(1+(∂ϵ_∂t/csp.C)^(1/csp.P)) |>units\n",
+ "end\n",
+ "#Ludwik\n",
+ "function plasticStress(σ_y::Pressure, ϵ_plastic::Real, ∂ϵ_∂t::Frequency, materialModel::MaterialModel, lwp::LudwikParams)::Pressure\n",
+ " σ_y + lwp.B*(ϵ_plastic)^lwp.C |> units #Ludwik's work hardening equation\n",
+ " end\n",
+ "#KN\n",
+ "function plasticStress(σ_y::Pressure, ϵ_plastic::Real, ∂ϵ_∂t::Frequency, materialModel::MaterialModel, knp::KNParams)::Pressure\n",
+ " knp.K*(ϵ_plastic)^knp.N |> units\n",
+ "end\n",
+ "#JohnsonCook\n",
+ "function plasticStress(σ_y::Pressure, ϵ_plastic::Real, ∂ϵ_∂t::Frequency, materialModel::MaterialModel,jcp::JohnsonCookParams)::Pressure\n",
+ " ((σ_y+jcp.B*(ϵ_plastic)^jcp.n)*(1+jcp.C*log(∂ϵ_∂t/jcp.∂ϵ_∂t_0))\n",
+ " *(1-((jcp.T_test-jcp.T_room)/(jcp.T_m-jcp.T_room))^jcp.m)) |> units\n",
+ "end\n",
+ "\n",
+ "#Fuction that gives the flow stress using the effective strain\n",
+ "function stress(ϵ, ∂ϵ_∂t::Frequency, materialModel::MaterialModel)::Pressure\n",
+ " σ_y = yieldStress(materialModel.plastic, materialModel, ∂ϵ_∂t)\n",
+ " if ϵ < σ_y/materialModel.E_y\n",
+ " return ϵ*materialModel.E_y\n",
+ " else\n",
+ " ϵ_plastic = ϵ - σ_y/materialModel.E_y\n",
+ " return plasticStress(σ_y, ϵ_plastic, ∂ϵ_∂t, materialModel, materialModel.plastic)\n",
+ " end\n",
+ "end\n",
+ "\n",
+ "\n",
+ "#= \n",
+ "σ_y-reference yield sress\n",
+ "E - Material's elastic modulus\n",
+ "E_t - Tangent modulus\n",
+ "E_y - Youngs Modulus\n",
+ "β - Hardening coefficient\n",
+ "ϵ^p - effective plastic strain\n",
+ "δϵ_δt - strain rate\n",
+ "δϵ_δt_0 - reference strain rate\n",
+ "C & P - strain-rate params of Cowper Symonds model\n",
+ "B,n,c & m - strain- and and strain-rate-dependent parameters of the Johnson-Cook material model\n",
+ "ϵ - strain\n",
+ "K - strength coefficient of the Hollomon equation\n",
+ "N - Strain hardening exponent of the Hollomon equation\n",
+ "k - strenght coefficient of the Ludwik equation\n",
+ "n - Strain hardening exponent of the Ludwik equation\n",
+ "=#"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "image/svg+xml": [
+ "\n",
+ "\n"
+ ]
+ },
+ "execution_count": 7,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "function plot6061()\n",
+ " #For Al 6061-T6\n",
+ " #Below are the CowperSymonds Constants\n",
+ " E_t = 600e6Pa\n",
+ " E = 72e9Pa\n",
+ " β = 1\n",
+ " #The above three parameters are used to calulate B. Sometimes they are given, sometimes not.\n",
+ " r = 208.8e6Pa #K-value for the cs model\n",
+ " A = 252e6Pa\n",
+ " B = β*(E_t*E)/(E-E_t)\n",
+ " #B = 451e6Pa\n",
+ " C = 25000Hz\n",
+ " n = 0.28\n",
+ " p = 1\n",
+ " P = 0.95\n",
+ " E_y = 68.9e9Pa\n",
+ " σ_y = A #Yeild Strength for the Ludwik equaiton\n",
+ " ∂ϵ_∂t = 6.7e-4Hz\n",
+ " k=640e6Pa\n",
+ " csp = CowperSymondsParams(A,B,C,p,P)\n",
+ " csp_matmod = MaterialModel(E_y,σ_y,csp)\n",
+ " ϵs = 0:0.0001:0.1\n",
+ " plot(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,csp_matmod)|> ustrip, ϵs)\n",
+ " ,linestyle = :dot\n",
+ " ,linewidth = 2\n",
+ " ,label=\"Cowper-Symonds (Quasi-Static)\"\n",
+ " ,title=\"Stess-Strain Al 6061-T6\"\n",
+ " ,legend = :bottomright)\n",
+ " ∂ϵ_∂t = 1kHz\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,csp_matmod)|> ustrip, ϵs)\n",
+ " ,linestyle = :auto\n",
+ " ,linewidth = 2\n",
+ " ,label=\"Cowper-Symonds (Fast-1kHz)\")\n",
+ " ∂ϵ_∂t = 1Hz\n",
+ "\n",
+ " #Below are the KN Constants\n",
+ " r = 530e6Pa\n",
+ " n = 0.14048\n",
+ " knp = KNParams(r,n)\n",
+ " knp_matmod = MaterialModel(E_y,σ_y,knp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,knp_matmod)|> ustrip, ϵs),linestyle = :dash,linewidth = 1,label=\"Power Function\")\n",
+ "\n",
+ " #Below are the JohnsonCook Constants (Source 1)\n",
+ " ∂ϵ_∂t_0 = 1Hz\n",
+ " T_room = 294.26K\n",
+ " T_m = 925.37K\n",
+ " T_test = 300K\n",
+ " #A = 289.6e6Pa\n",
+ " σ_y = A\n",
+ " B = 203.4e6Pa\n",
+ " c = 0.011\n",
+ " n = 0.35\n",
+ " h = 1.34 #This is the exponent on temperature for JohnsonCook\n",
+ " jcp = JohnsonCookParams(∂ϵ_∂t_0,T_room,T_m,T_test,A,B,c,n,h)\n",
+ " jcp_matmod = MaterialModel(E_y,σ_y,jcp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,jcp_matmod)|> ustrip, ϵs),linestyle = :dashdot,linewidth = 2,label=\"Johnson-Cook\")\n",
+ "\n",
+ " #Below are the Ludwik Constants\n",
+ " #A = 257.3e6Pa\n",
+ " σ_y = A\n",
+ " B = 208.8e6Pa\n",
+ " C = 0.28\n",
+ " lwp = LudwikParams(A,B,C)\n",
+ " lwp_matmod = MaterialModel(E_y,σ_y,lwp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,lwp_matmod)|> ustrip, ϵs),label=\"Ludwik\")\n",
+ "end\n",
+ "\n",
+ "plot6061()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 11,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "image/svg+xml": [
+ "\n",
+ "\n"
+ ]
+ },
+ "execution_count": 11,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "function plot7075()\n",
+ " #For Al 7075-T6\n",
+ "\n",
+ " #Below are the KN Constants\n",
+ " ϵs = 0:0.001:0.2\n",
+ " ∂ϵ_∂t = 1Hz #There's no information regarding the strain rate for both the KN and JC models, so I choose this value\n",
+ " r = 673e6Pa\n",
+ " n = 0.045\n",
+ " E_y = 71.7e9Pa\n",
+ " σ_y = 473e6Pa\n",
+ " knp = KNParams(r,n)\n",
+ " knp_matmod = MaterialModel(E_y,σ_y,knp)\n",
+ " plot(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,knp_matmod)|> ustrip, ϵs)\n",
+ " ,linestyle = :dot\n",
+ " ,linewidth = 4\n",
+ " ,label=\"Power Function\"\n",
+ " ,title=\"Stess-Strain Al 7075-T6\"\n",
+ " ,legend = :bottomright)\n",
+ "\n",
+ "\n",
+ " #Below are the JohnsonCook Constants (Source 2)\n",
+ " ∂ϵ_∂t_0 = 1Hz\n",
+ " T_room = 294.26K\n",
+ " T_m = 893K\n",
+ " T_test = 300K\n",
+ " A = σ_y\n",
+ " B = 210e6Pa\n",
+ " c = 0.033\n",
+ " n = 0.3813\n",
+ " h = 1 #This is the exponent on temperature for JohnsonCook\n",
+ " jcp = JohnsonCookParams(∂ϵ_∂t_0,T_room,T_m,T_test,A,B,c,n,h)\n",
+ " jcp_matmod = MaterialModel(E_y,σ_y,jcp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,jcp_matmod)|> ustrip, ϵs),label=\"Johnson-Cook\")\n",
+ "\n",
+ " #Below are the Ludwik Constants\n",
+ " #A = 184.0e6Pa\n",
+ " σ_y = A\n",
+ " B = 129.5e6Pa\n",
+ " C = 0.293\n",
+ " ∂ϵ_∂t = 800.0Hz\n",
+ " lwp = LudwikParams(A,B,C)\n",
+ " lwp_matmod = MaterialModel(E_y,σ_y,lwp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,lwp_matmod)|> ustrip, ϵs),label=\"Ludwik\")\n",
+ "end\n",
+ "\n",
+ "plot7075()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 13,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "image/svg+xml": [
+ "\n",
+ "\n"
+ ]
+ },
+ "execution_count": 13,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "function plotDQSK()\n",
+ " #For DQSK steel (automotive vehicles)\n",
+ "\n",
+ " #Johnson-Cook Parameters\n",
+ " ∂ϵ_∂t_0 = 1Hz\n",
+ " ∂ϵ_∂t = 1Hz\n",
+ " T_room = 294.26K\n",
+ " T_m = 1808K\n",
+ " T_test = 300K\n",
+ " A = 13e6Pa\n",
+ " σ_y = A\n",
+ " E_y = 206e9Pa\n",
+ " B = 730e6Pa\n",
+ " c = 0.045\n",
+ " n = 0.15\n",
+ " h = 0.5 #This is the exponent on temperature for JohnsonCook\n",
+ " ϵs = 0:0.001:0.2\n",
+ " jcp = JohnsonCookParams(∂ϵ_∂t_0,T_room,T_m,T_test,A,B,c,n,h)\n",
+ " jcp_matmod = MaterialModel(E_y,σ_y,jcp)\n",
+ " plot(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,jcp_matmod)|> ustrip, ϵs),label=\"Johnson-Cook 1Hz\")\n",
+ "\n",
+ " ∂ϵ_∂t = 1000Hz\n",
+ " jcp = JohnsonCookParams(∂ϵ_∂t_0,T_room,T_m,T_test,A,B,c,n,h)\n",
+ " jcp_matmod = MaterialModel(E_y,σ_y,jcp)\n",
+ " plot!(ϵs,map(ϵ -> stress(ϵ,∂ϵ_∂t,jcp_matmod)|> ustrip, ϵs),label=\"Johnson-Cook, 1kHz\")\n",
+ "end \n",
+ "\n",
+ "plotDQSK()"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": null,
+ "metadata": {},
+ "outputs": [],
+ "source": []
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "Julia 1.3.1",
+ "language": "julia",
+ "name": "julia-1.3"
+ },
+ "language_info": {
+ "file_extension": ".jl",
+ "mimetype": "application/julia",
+ "name": "julia",
+ "version": "1.3.1"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 2
+}