Recent content by mattskie
-
M
C/C++ C++ - dynamically allocating memory to array of structs
Thanks Mark! I figured out my issue!- mattskie
- Post #7
- Forum: Programming and Computer Science
-
M
C/C++ C++ - dynamically allocating memory to array of structs
my code only reads the "suit rank 0" 52 times instead of the correct "heart two 2" up to "spade ace 11".. so my code no longer seg faults, but something is wrong in my loop that copies the card..do you happen to have any insight to the problem?- mattskie
- Post #5
- Forum: Programming and Computer Science
-
M
C/C++ C++ - dynamically allocating memory to array of structs
#include <iostream> #include <fstream> #include <ctime> #include <stdlib.h> #include <string> using namespace std; //global constant(s) const int maxCards = 52; //Structs struct card { char *suit; char *rank; int cvalue; char location; }; //Function List void readPlayers(player...- mattskie
- Post #3
- Forum: Programming and Computer Science
-
M
C/C++ C++ - dynamically allocating memory to array of structs
Let me start by saying I know this is a funky way to program, but my teacher is requiring us to go about it this way. also: I CANT use std::string, classes, constructors for this project. I am required to use this archaic method of c-style strings with dynamic memory allocation occurring...- mattskie
- Thread
- Array C++ Memory
- Replies: 10
- Forum: Programming and Computer Science
-
M
Undergrad Is My Tri-Quadratic Curve Fit Equation Accurate Enough?
It doesn't appear that you are familiar with the way the LINEST function works, b ends up being the error +/- to fit the curve correctly. Much in the same way as bi-linear provides a b. I made the variables x,y,z for simplicities sake. If you need the data to provide the equation of a...- mattskie
- Post #3
- Forum: Linear and Abstract Algebra
-
M
Undergrad Is My Tri-Quadratic Curve Fit Equation Accurate Enough?
Hey, So I am trying to do a tri-quadratic curve fit (linear regression) in excel. I have successfully completed a bi-quadratic, and it is of the form: x+x^2+y+y^2+x*y+b (b is calculated by LINEST in excel) My attempt at a tri-linear was: x^2+x*y+x*z+y^2+y*z+z^2+b (b is calculated by...- mattskie
- Thread
- Replies: 2
- Forum: Linear and Abstract Algebra
-
M
Undergrad How can I accurately set up a tri-quadratic equation for curve fitting in Excel?
Hey, So I am trying to do a tri-quadratic curve fit (linear regression) in excel. I have successfully completed a bi-quadratic, and it is of the form: x+x^2+y+y^2+x*y+b (b is calculated by LINEST in excel) My attempt at a tri-linear was: x^2+x*y+x*z+y^2+y*z+z^2+b (b is calculated by...- mattskie
- Thread
- Replies: 1
- Forum: Set Theory, Logic, Probability, Statistics
-
M
How Do You Perform Cross Linear Interpolation for Suction Line Pressure?
This is not a homework problem, but... I am given the equation of two lines at different temperature gradients for (suction line temp,suction line pressure) => (x,y) At outdoor temp 95*F; y=.41667x+54.1667 At outdoor temp 85*F; y=.4231x+50.3846 I need to find suction line pressure for...- mattskie
- Thread
- Replies: 1
- Forum: Calculus and Beyond Homework Help
-
M
Undergrad Question regarding cross-linear interpolation
This is not a homework problem. I am given the equation of two lines at different temperature gradients for (suction line temp,suction line pressure) => (x,y) At outdoor temp 95*F; y=.41667x+54.1667 At outdoor temp 85*F; y=.4231x+50.3846 I need to find suction line pressure for 72*F temp...- mattskie
- Thread
- Interpolation
- Replies: 1
- Forum: General Math
-
M
Simplifying Boolean Algebra Expressions with K-maps
Homework Statement Show that F=wy'z+x'y'z+w'xy+wx'y+wxy = y'z+yw+yx Homework Equations Boolean Algebra.. The Attempt at a Solution F=y'z(x+x') + yw(x+x') + w'xy => y'z+yw+w'xy => y'z + y(w+w'x) => y'z + y + yw <-----stuck here what do i do? Not sure if this step is...- mattskie
- Thread
- Algebra Boolean algebra
- Replies: 1
- Forum: Engineering and Comp Sci Homework Help