Skip to content

CEM and enviro modules as used for umerc#96

Open
rebeccamccabe wants to merge 128 commits intomainfrom
anthony-enviro
Open

CEM and enviro modules as used for umerc#96
rebeccamccabe wants to merge 128 commits intomainfrom
anthony-enviro

Conversation

@rebeccamccabe
Copy link
Collaborator

No description provided.

% load data from MEEM (hardcoded, will replace later)
dat = readmatrix('mdocean/mdocean/inputs/validation/MEEM_validation/damping.csv');
w = dat(:,1);
mag = dat(:,2);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the data you are currently testing with is actually (k, B) rather than (w, mag).
try the following for better test data:

p = parameters();
b = var_bounds();
X = [b.X_noms; 1];
[~, ~, ~, ~, val] = simulation(X,p);
w = val.w;
F = val.gamma_f_over_rho_g * p.rho_w * p.g * p.Hs / (2*sqrt(2)) ;
X = val.X_f;
mag_matrix = X ./ F;
mag = mag_matrix(1,:); % all freqs at lowest wave height

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is empty, please check and push again

@codecov
Copy link

codecov bot commented Jun 12, 2025

❌ 40 Tests Failed:

Tests completed Failed Passed Skipped
83 40 43 0
View the top 3 failed test(s) by shortest run time
test::allFiguresRun(which_figs=Fig_24_ParetoFrontWithLCOEContours,which_tabs=none24)
Stack Traces | 0.000623s run time
Error occurred in test/allFiguresRun(which_figs=Fig_24_ParetoFrontWithLCOEContours,which_tabs=none24) and it did not run to completion.
    ---------
    Error ID:
    ---------
    'MATLAB:badsubscript'
    --------------
    Error Details:
    --------------
    Index exceeds the number of array elements. Index must not exceed 1.
    
    Error in pareto_search>get_seeds_epsilon_constraint (line 123)
        P_var_min = objs_opt(2);
    
    Error in pareto_search (line 18)
        [X0,fvals,probs] = get_seeds_epsilon_constraint(p,b,num_DVs,objFcn2,turnLCOEtoPower);
    
    Error in all_figures (line 216)
            pareto_search(filename_uuid);
    
    Error in test/runAllFigsTabs (line 123)
                     f_runtime_run,t_runtime_run] = all_figures( run_figs, run_tabs, testCase.uuid );
test::allFiguresRun(which_figs=Fig_36_DampingPlatePlateAspectRatio,which_tabs=none36)
Stack Traces | 0.000624s run time
Error occurred in test/allFiguresRun(which_figs=Fig_36_DampingPlatePlateAspectRatio,which_tabs=none36) and it did not run to completion.
    ---------
    Error ID:
    ---------
    'MATLAB:UndefinedFunction'
    --------------
    Error Details:
    --------------
    Unrecognized function or variable 'BoedoPrantilAnnularPlate'.
    
    Error in all_figures (line 289)
            BoedoPrantilAnnularPlate()
    
    Error in test/runAllFigsTabs (line 123)
                     f_runtime_run,t_runtime_run] = all_figures( run_figs, run_tabs, testCase.uuid );
test::allFiguresRun(which_figs=Fig_23_DesignAndObjectiveHeuristics,which_tabs=none23)
Stack Traces | 0.000625s run time
Error occurred in test/allFiguresRun(which_figs=Fig_23_DesignAndObjectiveHeuristics,which_tabs=none23) and it did not run to completion.
    ---------
    Error ID:
    ---------
    'MATLAB:badsubscript'
    --------------
    Error Details:
    --------------
    Index exceeds the number of array elements. Index must not exceed 1.
    
    Error in pareto_search>get_seeds_epsilon_constraint (line 123)
        P_var_min = objs_opt(2);
    
    Error in pareto_search (line 18)
        [X0,fvals,probs] = get_seeds_epsilon_constraint(p,b,num_DVs,objFcn2,turnLCOEtoPower);
    
    Error in all_figures (line 216)
            pareto_search(filename_uuid);
    
    Error in test/runAllFigsTabs (line 123)
                     f_runtime_run,t_runtime_run] = all_figures( run_figs, run_tabs, testCase.uuid );

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

Base automatically changed from force-saturation-fix to main June 16, 2025 21:41
anthnlong and others added 24 commits June 18, 2025 00:43
anthnlong and others added 27 commits August 7, 2025 16:54
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to appropriate foldere

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rename to remove _3

% calibrations of nominal values
b.F_max_nom = find_nominal_inputs(b, parameters(mode));

% FIXME: reminder to uncomment after debugging
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't merge this

nP = numel(pVals);

% interpolated values
%varsAll = Tsub.Properties.VariableNames;
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove commented

function [delta_CEM_CO2, CEM_wec_capacity, delta_CEM_grid_cost,margin_to_viability] = CEM_lookup_table(zeta, omega_n, capacity_cost, power_lim_frac, B_p, location, params)


%if zeta == 0.05 && omega_n == 0.4 && strcmp(location,'ISONE')
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove commented

delta_CEM_CO2 = CEM_CO2_no_wave - CEM_CO2;

%{
isValidLookupLocation = true;% placeholder
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove commented

in.location, in);


% old code that doesn't normalize with the number of WECs
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove commented

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't merge

@rebeccamccabe rebeccamccabe changed the title Anthony enviro CEM and enviro modules as used for umerc Sep 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants