Aaron-lyd / omega_u.s

Calculating a series of omega surface.
0 stars 0 forks source link

including MATLAB source code, not MEX code #1

Open geoffstanley opened 1 year ago

geoffstanley commented 1 year ago

In lib_add, there's two *.mexmaci64 files, for ppc_val and ppc_val2. These will only work for a user who has the same computer architecture as you, in this case an i64 mac. Instead, we need to provide the MATLAB source code (.m files) that underlies these functions (which is already given in lib/ppc/). Anyone can run the .m files, though they will be slower than the mex compiled versions.

In this case, for Neutral-Surfaces I did not provide code to compile (i.e. run codegen on) the ppc_val and ppc_val2. Instead, I provided code to compile other functions that themselves call ppc_val2. For example, the ntp_slope function can be compiled, and indeed already provide the ntp_slope_codegen.m function that wraps the call to codegen on ntp_slope.

Likewise, we should delete other *.mexmaci64 files throughout this repo, and make sure that any user can compile what's needed.

Perhaps all that we need to do is delete the *.mexmaci64 files. Later, I'll test if I can run your scripts in a fresh MATLAB environment.

Aaron-lyd commented 1 year ago

That makes sense.