Skip to content

Commit

Permalink
BulkViscosity
Browse files Browse the repository at this point in the history
  • Loading branch information
srosenbu committed Oct 26, 2023
1 parent 97c54e6 commit 48247a2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/jh2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@ use crate::stress_strain::{
deviatoric, mandel_decomposition, mandel_rate_from_velocity_gradient, MANDEL_IDENTITY,
};

use nalgebra::SMatrix;
use nalgebra::{SMatrix, DVectorView};
use std::cmp;
use std::collections::HashMap;

#[derive(Debug)]
pub struct JH2Parameters {
pub struct JH2ConstParameters {
pub RHO: f64,
pub SHEAR_MODULUS: f64,
pub A: f64,
Expand All @@ -31,13 +30,13 @@ pub struct JH2Parameters {
}
#[derive(Debug)]
pub struct JH23D {
parameters: JH2Parameters,
parameters: JH2ConstParameters,
}

impl ConstitutiveModel for JH23D {
fn new(parameters: &HashMap<String, f64>) -> Self {
Self {
parameters: JH2Parameters {
parameters: JH2ConstParameters {
RHO: *parameters.get("RHO").unwrap(),
SHEAR_MODULUS: *parameters.get("SHEAR_MODULUS").unwrap(),
A: *parameters.get("A").unwrap(),
Expand Down Expand Up @@ -285,6 +284,7 @@ impl ConstitutiveModel for JH23D {
(Q::InternalPlasticEnergy, QDim::Scalar),
(Q::InternalElasticEnergy, QDim::Scalar),
(Q::InternalEnergy, QDim::Scalar),
(Q::BulkViscosity, QDim::Scalar),
])
}

Expand Down

0 comments on commit 48247a2

Please sign in to comment.