Changeset 26648
- Timestamp:
- 11/19/21 07:31:51 (3 years ago)
- Location:
- issm/trunk-jpl/src/jl/solve
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/jl/solve/analyses.jl
r26634 r26648 54 54 end#}}} 55 55 function GetSolutionFromInputs(analysis::StressbalanceAnalysis,ug::Vector{Float64},element::Tria) #{{{ 56 error("STOP") 56 57 #Get dofs for this finite element 58 doflist = GetDofList(element,GsetEnum) 59 error("S") 60 57 61 end#}}} 58 62 -
issm/trunk-jpl/src/jl/solve/elements.jl
r26629 r26648 39 39 #Configure vertices 40 40 for i in 1:3 41 41 element.vertices[i] = vertices[element.vertexids[i]] 42 42 end 43 43 … … 52 52 53 53 end # }}} 54 function GetDofList(element::Tria,setenum::IssmEnum) # {{{ 55 56 #Define number of nodes 57 numnodes = 3 58 59 #Determine size of doflist 60 numdofs = 0 61 for i in 1:numnodes 62 numdofs += GetNumberOfDofs(element.nodes[i],GsetEnum) 63 end 64 65 #Allocate doflist vector 66 doflist = Vector{Int64}(undef,numdofs) 67 68 #enter dofs in doflist vector 69 count = 0 70 for i in 1:numnodes 71 count = GetDofList(element.nodes[i],doflist,count,GsetEnum) 72 end 73 74 println(doflist) 75 error("S") 76 77 end # }}} -
issm/trunk-jpl/src/jl/solve/modules.jl
r26634 r26648 45 45 tempparams = Parameters(Dict{IssmEnum,Parameter}()) 46 46 tempinputs = Inputs(-1,-1,Dict{IssmEnum,Input}()) 47 tempvertices = Vector{Vertex}(undef,3)48 tempnodes = Vector{Node}(undef,3)49 47 50 48 count = 0 … … 56 54 57 55 #Call constructor and add to dataset elements 58 push!(elements,Tria(i,count,vertexids, tempvertices,nodeids,tempnodes,tempparams,tempinputs))56 push!(elements,Tria(i,count,vertexids,Vector{Vertex}(undef,3),nodeids,Vector{Node}(undef,3),tempparams,tempinputs)) 59 57 end 60 58 … … 125 123 gsize = NumberOfDofs(femmodel.nodes,GsetEnum) 126 124 127 println(gsize)128 error("Stop ===")129 130 125 #Initialize solution vector 131 126 ug = Vector{Float64}(undef,gsize) -
issm/trunk-jpl/src/jl/solve/nodes.jl
r26634 r26648 86 86 87 87 end# }}} 88 function GetDofList(node::Node,doflist::Vector{Int64},count::Int64,setenum::IssmEnum) #{{{ 89 90 if setenum==GsetEnum 91 for i in 1:node.gsize 92 count += 1 93 doflist[count] = node.gdoflist[i] 94 end 95 elseif setenum==FsetEnum 96 for i=1:node.gsize 97 if node.fdoflist[i]!=-1 98 count += 1 99 doflist[count] = node.fdoflist[i] 100 end 101 end 102 elseif setenum==SsetEnum 103 for i=1:node.gsize 104 if node.sdoflist[i]!=-1 105 count += 1 106 doflist[count] = node.sdoflist[i] 107 end 108 end 109 else 110 error("not supported") 111 end 112 113 return count 114 115 end# }}} 88 116 89 117 #Nodes functions
Note:
See TracChangeset
for help on using the changeset viewer.