Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Frida
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Coenen, Joachim
Frida
Commits
b2cb02be
Commit
b2cb02be
authored
9 years ago
by
Wuttke, Joachim
Committed by
Wuttke, Joachim
9 years ago
Browse files
Options
Downloads
Patches
Plain Diff
start NodeFileNJ, but there is a conceptual problem with ObjVec
parent
636bd1df
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
pub/lib/node.cpp
+25
-3
25 additions, 3 deletions
pub/lib/node.cpp
pub/lib/node.hpp
+22
-0
22 additions, 0 deletions
pub/lib/node.hpp
with
47 additions
and
3 deletions
pub/lib/node.cpp
+
25
−
3
View file @
b2cb02be
...
@@ -748,6 +748,31 @@ const RObj CNodeSessionNK::tree_val( const CContext& ctx ) const
...
@@ -748,6 +748,31 @@ const RObj CNodeSessionNK::tree_val( const CContext& ctx ) const
}
}
//**************************************************************************************************
//* CNodeFile: file-wide information
//**************************************************************************************************
/*
const RObj CNodeFile::tree_val( const CContext& ctx ) const
{
int k = ref->get_k( ctx );
POlo f = NOlm::mem_get(k);
if ( ctx.dim==CContext::_VI ) {
CContext myctx = ctx;
myctx.dim = CContext::_1;
PObjVecEnu pret( new CObjVecEnu( ctx.nv ) );
for ( int ii=0; ii<ctx.nv; ++ii ) {
myctx.i = ii;
// pret->v[ii] = f->V[j]->z[var->num]->to_r();
}
return pret;
} else {
// return f->V[j]->z[var->num];
}
return RObjInt( new CObjInt( 0 ) );
}
*/
//**************************************************************************************************
//**************************************************************************************************
//* CNodeIva: indexed variable node
//* CNodeIva: indexed variable node
//**************************************************************************************************
//**************************************************************************************************
...
@@ -770,10 +795,7 @@ const RObj CNodeIva::tree_val( const CContext& ctx ) const
...
@@ -770,10 +795,7 @@ const RObj CNodeIva::tree_val( const CContext& ctx ) const
if
(
!
(
var
->
pointwise
()
||
var
->
slicewise
()
||
var
->
filewise
())
&&
ref
->
tk
)
if
(
!
(
var
->
pointwise
()
||
var
->
slicewise
()
||
var
->
filewise
())
&&
ref
->
tk
)
throw
"reference "
+
var
->
var_info
()
+
" does not admit an index"
;
throw
"reference "
+
var
->
var_info
()
+
" does not admit an index"
;
// Get k from context:
int
k
=
ref
->
get_k
(
ctx
);
int
k
=
ref
->
get_k
(
ctx
);
// Proceed with file reference f[k]:
POlo
f
=
NOlm
::
mem_get
(
k
);
POlo
f
=
NOlm
::
mem_get
(
k
);
if
(
var
->
categ
==
VCateg
::
NJ
)
{
if
(
var
->
categ
==
VCateg
::
NJ
)
{
...
...
This diff is collapsed.
Click to expand it.
pub/lib/node.hpp
+
22
−
0
View file @
b2cb02be
...
@@ -197,6 +197,28 @@ class CNodeSessionNK: public CNode {
...
@@ -197,6 +197,28 @@ class CNodeSessionNK: public CNode {
};
};
//! File-wide information.
class
CNodeFile
:
public
CNode
{
private:
RRef1
ref
;
public:
CNodeFile
(
RRef1
_ref
=
RRef1
(
new
CRef1
()
)
)
:
ref
(
_ref
)
{}
const
RObj
tree_val
(
const
CContext
&
ctx
)
const
;
void
kdep_exec
(
bool
*
kd
)
const
{
*
kd
=
true
;
}
};
//! File-wide information: NJ = number of slices.
class
CNodeFileNJ
:
public
CNodeFile
{
public:
CNodeFileNJ
(
RRef1
_ref
=
RRef1
(
new
CRef1
()
)
)
:
CNodeFile
(
_ref
)
{}
void
set_coord
(
CCoord
&
ret
,
int
k
)
const
{
ret
=
CCoord
(
"nj"
,
""
);
}
string
tree_info
()
const
{
return
"nj {number of slices}"
;
}
};
//! Indexed variable node.
//! Indexed variable node.
class
CNodeIva
:
public
CNode
{
class
CNodeIva
:
public
CNode
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment