-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #127 from tawhai/unit_ventilation
Unit ventilation
- Loading branch information
Showing
27 changed files
with
1,770 additions
and
812 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,18 @@ | ||
|
||
#include "arrays.h" | ||
#include "string.h" | ||
|
||
void set_node_field_value_c(int *row, int *col, double *value); | ||
void update_parameter_c(const char *parameter_name, int *parameter_name_len, double *parameter_value); | ||
|
||
void set_node_field_value(int row, int col, double value) | ||
{ | ||
set_node_field_value_c(&row, &col, &value); | ||
} | ||
|
||
void update_parameter(const char *parameter_name, double parameter_value) | ||
{ | ||
int parameter_name_len = (int)strlen(parameter_name); | ||
update_parameter_c(parameter_name, ¶meter_name_len, ¶meter_value); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,18 @@ | ||
|
||
#include "gas_exchange.h" | ||
|
||
void steadystate_gasexchange_c(double *c_art_o2, double *c_ven_o2, | ||
double *p_art_co2, double *p_art_o2, double *p_i_o2, double *p_ven_co2, double *p_ven_o2, double *shunt_fraction, | ||
double *VCO2, double *VO2); | ||
void initial_gasexchange_c(double *initial_concentration, double *surface_area, double *V_cap); | ||
|
||
void steadystate_gasexchange(double *c_art_o2, double *c_ven_o2, | ||
double *p_art_co2, double *p_art_o2, double *p_i_o2, double *p_ven_co2, double *p_ven_o2, double *shunt_fraction, | ||
double *VCO2, double *VO2) | ||
void steadystate_gasexchange_c(double *deadspace, double *p_i_o2, double *shunt_fraction, double *target_p_art_co2, double *target_p_ven_o2, double *VCO2, double *VO2); | ||
|
||
|
||
void initial_gasexchange(double initial_concentration, double surface_area, double V_cap) | ||
{ | ||
initial_gasexchange_c(&initial_concentration, &surface_area, &V_cap); | ||
} | ||
|
||
void steadystate_gasexchange(double deadspace, double p_i_o2, double shunt_fraction, double target_p_art_co2, double target_p_ven_o2, double VCO2, double VO2) | ||
{ | ||
steadystate_gasexchange_c(c_art_o2, c_ven_o2, p_art_co2, p_art_o2, p_i_o2, p_ven_co2, p_ven_o2, shunt_fraction, VCO2, VO2); | ||
steadystate_gasexchange_c(&deadspace, &p_i_o2, &shunt_fraction, &target_p_art_co2, &target_p_ven_o2, &VCO2, &VO2); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.