-
Notifications
You must be signed in to change notification settings - Fork 624
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
matlab: Parse variables in Matlab cod
- Loading branch information
Showing
6 changed files
with
36 additions
and
0 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,4 +1,14 @@ | ||
backtrack input.m /^function [xn,fn,fcall] = backtrack(xc,d,fc,fnc,DDfnc,c,gamma,eps)$/;" f | ||
cDDfnc input.m /^ cDDfnc = gamma*cDDfnc;$/;" v | ||
cDDfnc input.m /^cDDfnc = c*DDfnc;$/;" v | ||
d input.m /^ d = gamma*d;$/;" v | ||
fcall input.m /^ fcall = fcall+1;$/;" v | ||
fcall input.m /^fcall = 1 ;$/;" v | ||
fn input.m /^ fn = feval(fnc,xn);$/;" v | ||
fn input.m /^fn = feval(fnc,xn);$/;" v | ||
func1 input.m /^function [x,y,z] = func1 $/;" f | ||
func2 input.m /^function x = func2 $/;" f | ||
func3 input.m /^function func3 $/;" f | ||
xn input.m /^ xn = xc;$/;" v | ||
xn input.m /^ xn = xc+d;$/;" v | ||
xn input.m /^xn = xc+d;$/;" v |
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,4 +1,14 @@ | ||
backtrack input.nolang /^function [xn,fn,fcall] = backtrack(xc,d,fc,fnc,DDfnc,c,gamma,eps)$/;" f | ||
cDDfnc input.nolang /^ cDDfnc = gamma*cDDfnc;$/;" v | ||
cDDfnc input.nolang /^cDDfnc = c*DDfnc;$/;" v | ||
d input.nolang /^ d = gamma*d;$/;" v | ||
fcall input.nolang /^ fcall = fcall+1;$/;" v | ||
fcall input.nolang /^fcall = 1 ;$/;" v | ||
fn input.nolang /^ fn = feval(fnc,xn);$/;" v | ||
fn input.nolang /^fn = feval(fnc,xn);$/;" v | ||
func1 input.nolang /^function [x,y,z] = func1 $/;" f | ||
func2 input.nolang /^function x = func2 $/;" f | ||
func3 input.nolang /^function func3 $/;" f | ||
xn input.nolang /^ xn = xc;$/;" v | ||
xn input.nolang /^ xn = xc+d;$/;" v | ||
xn input.nolang /^xn = xc+d;$/;" v |
10 changes: 10 additions & 0 deletions
10
Units/review-needed.r/matlab_backtracking.m.t/expected.tags
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 +1,11 @@ | ||
backtrack input.m /^function [xn,fn,fcall] = backtrack(xc,d,fc,fnc,DDfnc,c,gamma,eps)$/;" f | ||
cDDfnc input.m /^ cDDfnc = gamma*cDDfnc;$/;" v | ||
cDDfnc input.m /^cDDfnc = c*DDfnc;$/;" v | ||
d input.m /^ d = gamma*d;$/;" v | ||
fcall input.m /^ fcall = fcall+1;$/;" v | ||
fcall input.m /^fcall = 1 ;$/;" v | ||
fn input.m /^ fn = feval(fnc,xn);$/;" v | ||
fn input.m /^fn = feval(fnc,xn);$/;" v | ||
xn input.m /^ xn = xc;$/;" v | ||
xn input.m /^ xn = xc+d;$/;" v | ||
xn input.m /^xn = xc+d;$/;" v |
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,3 +1,5 @@ | ||
A input.m /^A = magic(4);$/;" v | ||
R input.m /^R = randn(3,4,5);$/;" v | ||
func1 input.m /^function [x,y,z] = func1 $/;" f | ||
func2 input.m /^function x = func2 $/;" f | ||
func3 input.m /^function func3 $/;" f |
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 |
---|---|---|
|
@@ -2,3 +2,5 @@ | |
function x = func2 | ||
function func3 | ||
|
||
A = magic(4); | ||
R = randn(3,4,5); |
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